Skip to content

Instantly share code, notes, and snippets.

View bmoore01's full-sized avatar

Ben Moore bmoore01

View GitHub Profile
@bmoore01
bmoore01 / laninfo.sh
Created May 14, 2017 04:34
A script to find out out information and do a ports can of everything on your network
#!/bin/bash
# get local ip from ifconfig
localIP=($(sudo ifconfig | grep "inet " | awk '{print $2}' | awk 'END{print}' ))
# affix two wildcards to the end of local IP
startIP=`echo $localIP | cut -d "." -f1-3`
@bmoore01
bmoore01 / backup_dots.sh
Created May 7, 2016 18:49
A script that backs up my dotfiles to github
#!/bin/bash
# variables
gitdir=~/git-dotfiles
dir=~/dotfiles
files="xres cmus config fehbg themes bashrc xinitrc XResources"
NOW=$(date +"%H:%M-%D")
# if directories do not exist create them
mkdir -p $dir
double a;
double b;
double c;
double d;
double sum;
double product;
for(a = 0.1;a <= 7.11;a += 0.1) {
for(b = 0.1;b <= 7.11;b += 0.1) {
for(c = 0.1;c <= 7.11;c += 0.1) {