lib/aliases.zsh
6ef2e1f5
 #!/bin/zsh
 
 # Push and pop directories on directory stack
5da20b9d
 alias pu='pushd'
 alias po='popd'
538c54ba
 
da3be21b
 alias ss='thin --stats "/thin/stats" start'
788c9af0
 alias sg='ruby script/generate'
 alias sd='ruby script/destroy'
 alias sp='ruby script/plugin'
 alias ssp='ruby script/spec'
 alias rdbm='rake db:migrate'
fd6861b8
 alias sc='ruby script/console'
 alias sd='ruby script/server --debugger'
83309294
 alias devlog='tail -f log/development.log'
5da20b9d
 
6ef2e1f5
 # Basic directory operations
5da20b9d
 alias .='pwd'
 alias ...='cd ../..'
60e99779
 alias -- -='cd -'
5da20b9d
 
6ef2e1f5
 # Super user
5da20b9d
 alias _='sudo'
8176645e
 alias ss='sudo su -'
5da20b9d
 
0f2e63f8
 #alias g='grep -in'
1875755f
 
6ef2e1f5
 # Git related
0f2e63f8
 alias g='git'
1875755f
 alias gst='git status'
 alias gl='git pull'
788c9af0
 alias gup='git fetch && git rebase'
1875755f
 alias gp='git push'
 alias gd='git diff | mate'
7705ffaf
 alias gdv='git diff -w "$@" | vim -R -'
1875755f
 alias gc='git commit -v'
 alias gca='git commit -v -a'
 alias gb='git branch'
 alias gba='git branch -a'
788c9af0
 alias gcount='git shortlog -sn'
b6c8ef41
 alias gcp='git cherry-pick'
5da20b9d
 
6ef2e1f5
 # Show history
5da20b9d
 alias history='fc -l 1'
 
6ef2e1f5
 # List direcory contents
08fcf7dc
 alias lsa='ls -lah'
6ef2e1f5
 alias l='ls -la'
8176645e
 alias ll='ls -alr'
 alias sl=ls # often screw this up
5da20b9d
 
 alias sgem='sudo gem'
 
6ef2e1f5
 # Find ruby file
5da20b9d
 alias rfind='find . -name *.rb | xargs grep -n'
fdac2b3f
 alias afind='ack-grep -il'
5da20b9d
 
6ef2e1f5
 # Git and svn mix
5da20b9d
 alias git-svn-dcommit-push='git svn dcommit && git push github master:svntrunk'
 
6ef2e1f5
 # TextMate
7a7b0bc7
 alias et='mate . &'
 alias ett='mate app config lib db public spec test Rakefile Capfile Todo &'
 alias etp='mate app config lib db public spec test vendor/plugins vendor/gems Rakefile Capfile Todo &'
 alias etts='mate app config lib db public script spec test vendor/plugins vendor/gems Rakefile Capfile Todo &'
6ef2e1f5
 
 # Editor Ruby file in TextMate
fd6861b8
 alias mr='mate CHANGELOG app config db lib public script spec test'