Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100755 99 lines (77 sloc) 3.031 kb
cd95319 initial commit. many thanks to the people I've shamelessly taken bits or...
Kyle Fring authored
1 ##
2 # GENERAL BASH Shortcuts
3 ##
90f5f28 updated LS aliases
Kyle Fring authored
4 alias l='ls -G'
5 alias ll='ls -FlahG' # l for list style, a for all including hidden, h for human readable file sizes
cd95319 initial commit. many thanks to the people I've shamelessly taken bits or...
Kyle Fring authored
6 alias h='history' # shortcut for history
7 alias ..='cd ..' # move up 1 dir
8 alias ...='cd ../..' # move up 2 dirs
3f47e53 .
Kyle Fring authored
9 alias c='clear'
cd95319 initial commit. many thanks to the people I've shamelessly taken bits or...
Kyle Fring authored
10
11
12 # List only directories
13 alias lsd='ls -l | grep "^d"'
14
15 # IP addresses
16 alias ip="dig +short myip.opendns.com @resolver1.opendns.com"
17 alias localip="ipconfig getifaddr en1"
18 alias ips="ifconfig -a | perl -nle'/(\d+\.\d+\.\d+\.\d+)/ && print $1'"
19
20 # Flush Directory Service cache
21 alias flush="dscacheutil -flushcache"
22
23 # View HTTP traffic
24 alias sniff="sudo ngrep -d 'en1' -t '^(GET|POST) ' 'tcp and port 80'"
25 alias httpdump="sudo tcpdump -i en1 -n -s 0 -w - | grep -a -o -E \"Host\: .*|GET \/.*\""
26
27 # File size
28 alias fs="stat -f \"%z bytes\""
29
30 # ROT13-encode text. Works for decoding, too! ;)
31 alias rot13='tr a-zA-Z n-za-mN-ZA-M'
32
33 ##
34 # SERIAL CONNECTIONS
35 ##
36 alias tty='ls /dev/tty.*'
37 alias s9600='screen /dev/tty.PL2303-000012FD 9600'
38
39 # Don't put duplicate lines in the history.
40 export HISTCONTROL=$HISTCONTROL${HISTCONTROL+,}ignoredups
41 export HISTCONTROL=ignoreboth
42
43 # fun with rainbows...
44 alias lulz='cat /dev/urandom | base64 -b 80 | lolcat'
45
46 # Colorize Grep
47 alias grep='GREP_COLOR="1;37;41" LANG=C grep --color=auto'
48
49 # Shortcuts
50 alias d="cd ~/Documents/Dropbox"
51 alias p="cd ~/Projects"
52 alias g="git"
53 alias v="vim"
54
55 # Show/hide hidden files in Finder
56 alias show="defaults write com.apple.Finder AppleShowAllFiles -bool true && killall Finder"
57 alias hide="defaults write com.apple.Finder AppleShowAllFiles -bool false && killall Finder"
58
59 # Hide/show all desktop icons (useful when presenting)
60 alias hidedesktop="defaults write com.apple.finder CreateDesktop -bool false && killall Finder"
61 alias showdesktop="defaults write com.apple.finder CreateDesktop -bool true && killall Finder"
62
63 # Disable Spotlight
64 alias spotoff="sudo mdutil -a -i off"
65 # Enable Spotlight
66 alias spoton="sudo mdutil -a -i on"
67
68 # Create a logfile out to $HOME/Logs
69 alias log="$HOME/.bashscripts/dolog.sh"
70
71 # Make a DMG into an ISO (#dmg2iso fileOne.dmg newFile.iso)
72 alias dmg2iso="$HOME/.bashscripts/dmg2iso.sh"
73
74 # Stuff I never really use but cannot delete either because of http://xkcd.com/530/
75 alias stfu="osascript -e 'set volume output muted true'"
76 alias pumpitup="osascript -e 'set volume 10'"
77 alias hax="growlnotify -a 'Activity Monitor' 'System error' -m 'WTF R U DOIN'"
78
79 # Ostianto
80 alias ost="sudo /Applications/Ostinato.app/Contents/MacOS/Ostinato"
76cbbdb Fixed SublimeText CLI tool
Kyle Fring authored
81
82 # GIT Shortcuts (http://www.renownedmedia.com)
83 alias ga='git add'
84 alias gp='git push'
85 alias gl='git log'
86 alias gs='git status'
87 alias gd='git diff'
88 alias gm='git commit -m'
89 alias gma='git commit -am'
90 alias gb='git branch'
91 alias gc='git checkout'
92 alias gra='git remote add'
93 alias grr='git remote rm'
94 alias gpu='git pull'
95 alias gcl='git clone'
20d014c no message
l00pback0 authored
96
97 # SVN Shortcut to remove all dead files
b1a2c5a fix svndead alias later.
l00pback0 authored
98 #alias svndead='svn status | sed -Ee '/^!/!d' -e 's/^! *(.*)/"\1"/g' | xargs -L1 svn rm'
Something went wrong with that request. Please try again.