2013-07-07 21:25:47 +00:00
|
|
|
# Handle the fact that this file will be used with multiple OSs
|
|
|
|
platform=`uname`
|
|
|
|
if [[ $platform == 'Linux' ]]; then
|
2013-07-07 21:30:11 +00:00
|
|
|
alias l='ls -l --color'
|
|
|
|
alias ll='ls -lrth --color'
|
2013-07-07 21:25:47 +00:00
|
|
|
elif [[ $platform == 'Darwin' ]]; then
|
2013-07-07 21:30:11 +00:00
|
|
|
alias l='ls -laG'
|
|
|
|
alias ll='ls -lG'
|
2013-07-07 21:25:47 +00:00
|
|
|
fi
|
|
|
|
|
2013-07-07 21:30:11 +00:00
|
|
|
alias c='cd'
|
|
|
|
alias cd-='cd -'
|
|
|
|
alias ..='cd ../'
|
|
|
|
alias ...='cd ../..'
|
|
|
|
alias cd..='cd ..'
|
|
|
|
alias cd...='cd ../..'
|
|
|
|
alias cd....='cd ../../..'
|
|
|
|
alias cd.....='cd ../../../..'
|
|
|
|
alias cd/='cd /'
|
|
|
|
alias ls='ls -G'
|
|
|
|
|
2013-07-07 21:25:47 +00:00
|
|
|
alias aliases='vim ~/.dotfiles/zsh/aliases'
|
2013-07-10 16:13:13 +00:00
|
|
|
alias b='bundle'
|
2013-07-07 21:25:47 +00:00
|
|
|
alias bake='bundle exec rake'
|
|
|
|
alias be='bundle exec'
|
|
|
|
alias bi='bundle install'
|
|
|
|
alias be='bundle exec'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias beg='bundle exec guard'
|
2013-07-07 21:25:47 +00:00
|
|
|
alias bu='bundle update'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias cls=clear
|
2013-07-07 21:25:47 +00:00
|
|
|
alias code='cd ~/code'
|
2013-07-17 22:46:38 +00:00
|
|
|
alias cpr='cp -r'
|
2013-07-07 21:25:47 +00:00
|
|
|
alias d='cd ~/.dotfiles'
|
|
|
|
alias dr='cd ~/Dropbox'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias duh='du -csh'
|
2013-07-10 16:13:13 +00:00
|
|
|
alias functions='vim ~/.dotfiles/zsh/functions'
|
|
|
|
alias f='fg'
|
|
|
|
alias history='fc -l 1'
|
|
|
|
alias h='heroku'
|
|
|
|
alias irb='irb --readline -r irb/completion'
|
|
|
|
alias patch='git format-patch HEAD^ --stdout > patch.diff'
|
|
|
|
alias reguard='killall -9 ruby ; guard'
|
|
|
|
alias r='rails'
|
2013-07-17 22:46:38 +00:00
|
|
|
alias rb='rbenv'
|
2013-07-16 23:36:06 +00:00
|
|
|
alias rmr='rm -rf'
|
2013-07-10 16:13:13 +00:00
|
|
|
alias rc='rails console'
|
|
|
|
alias reload='source ~/.zshrc'
|
|
|
|
alias tail-logs='heroku logs -t'
|
|
|
|
alias u='cd ..'
|
|
|
|
alias v='vim'
|
|
|
|
alias vi='vim'
|
|
|
|
alias vimrc='vim ~/.vimrc'
|
2013-07-16 23:36:06 +00:00
|
|
|
alias q='quirk'
|
2013-07-17 22:46:38 +00:00
|
|
|
alias qe='quirk -e'
|
2013-07-16 23:36:06 +00:00
|
|
|
alias qc='quirk -c'
|
|
|
|
alias qm='quirk -m'
|
|
|
|
alias qq='quirk -t'
|
2013-07-10 16:13:13 +00:00
|
|
|
alias zsh='vim ~/.zshrc'
|
|
|
|
|
2013-07-07 21:30:11 +00:00
|
|
|
|
|
|
|
# Git
|
|
|
|
alias ammend='amend'
|
|
|
|
alias amend='git commit --amend'
|
|
|
|
alias gaa='echo "Use ga!" && git add --all'
|
|
|
|
alias ga='git add --all'
|
|
|
|
alias gae='echo "Use amend!" && git commit --amend' # Remove when not needed
|
|
|
|
alias gau='git add --update'
|
|
|
|
alias gb='git branch'
|
2013-07-16 23:36:06 +00:00
|
|
|
alias gbd='git branch -D'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gc='git commit'
|
|
|
|
alias gci='echo "Use gc!" && git commit' # Remove when no longer needed
|
2013-07-07 21:25:47 +00:00
|
|
|
alias gcl='git clone'
|
|
|
|
alias gcm="git commit -m"
|
|
|
|
alias gco='git checkout'
|
2013-07-16 23:36:06 +00:00
|
|
|
alias gcob='git checkout -b'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gcp='git cherry-pick'
|
2013-07-07 21:25:47 +00:00
|
|
|
alias gd='git diff'
|
|
|
|
alias gdc='git diff --cached'
|
|
|
|
alias gdm='git diff master'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gds='git diff --stat=160,120'
|
|
|
|
alias gdw='git diff --color-words'
|
|
|
|
alias gf='git fetch'
|
|
|
|
alias gh="source ~/.githelpers && show_git_head"
|
2013-07-10 16:13:13 +00:00
|
|
|
alias gl='gll -25'
|
|
|
|
alias gll="source ~/.githelpers && pretty_git_log"
|
|
|
|
alias gla='gll --all'
|
|
|
|
alias gmff='git merge --ff-only'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gmtheirs='git merge -Xtheirs'
|
2013-07-07 21:25:47 +00:00
|
|
|
alias gp='git push'
|
|
|
|
alias gpf='git push -f'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gpff='git pull --ff-only'
|
2013-07-10 16:13:13 +00:00
|
|
|
alias gpl='git pull'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gpom='git push origin master'
|
2013-07-07 21:25:47 +00:00
|
|
|
alias gpr='git pull --rebase'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gr='git reset'
|
2013-07-10 16:13:13 +00:00
|
|
|
alias grbm='git rebase master'
|
2013-07-07 21:25:47 +00:00
|
|
|
alias grc='git rebase --continue'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gre='git remote'
|
2013-07-16 15:24:18 +00:00
|
|
|
alias grm='git rm'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gsnapshot='git stash save "snapshot: $(date)" && git stash apply "stash@{0}"'
|
|
|
|
alias gst='git status'
|
|
|
|
alias gs='git stash'
|
2013-07-17 22:46:38 +00:00
|
|
|
alias gss='git stash save'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias gsd='git stash drop'
|
|
|
|
alias gsl='git stash list'
|
|
|
|
alias gsp='git stash pop'
|
|
|
|
alias gx='git reset --hard'
|
|
|
|
|
|
|
|
# Notes
|
|
|
|
alias todo='vim ~/Dropbox/notes/life-todo'
|
2013-07-10 16:13:13 +00:00
|
|
|
alias wtodo='vim ~/Dropbox/work/redwood/notes/work-todo'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias sharp='vim ~/Dropbox/notes/sharpening-notes'
|
2013-07-08 11:22:06 +00:00
|
|
|
alias completion='vim ~/Dropbox/notes/completion-list'
|
2013-07-10 16:13:13 +00:00
|
|
|
alias powerup='vim ~/code/learning-area/notes/powerup'
|
|
|
|
alias pnotes='vim ~/Dropbox/notes/programming-notes'
|
|
|
|
alias wnotes='vim ~/Dropbox/work/redwood/notes/project-notes'
|
2013-07-07 21:25:47 +00:00
|
|
|
|
2013-07-07 21:30:11 +00:00
|
|
|
# Projects
|
|
|
|
alias projects='cd ~/code/projects'
|
2013-07-08 11:22:06 +00:00
|
|
|
alias dot='cd ~/code/projects/dotfiles'
|
2013-07-10 16:13:13 +00:00
|
|
|
alias p='cd ~/code/work/redwood/campusperks'
|
2013-07-16 15:24:18 +00:00
|
|
|
alias work='cd ~/code/work/redwood'
|
2013-07-07 21:30:11 +00:00
|
|
|
alias learn='cd ~/code/learning-area'
|
2013-07-08 11:22:06 +00:00
|
|
|
alias current='cd ~/code/learning-area/languages-frameworks/elixir/introducing-elixir/physics'
|
2013-07-07 21:25:47 +00:00
|
|
|
|
2013-07-07 21:30:11 +00:00
|
|
|
# Heroku staging
|
|
|
|
alias staging-console='heroku run console --app campusperks-staging'
|
|
|
|
alias staging-tail='heroku logs --tail --app campusperks-staging'
|
2013-07-07 21:25:47 +00:00
|
|
|
|
2013-07-07 21:30:11 +00:00
|
|
|
# Heroku production
|
|
|
|
alias production-console='heroku run console --app campusperks'
|
|
|
|
alias production-tail='heroku logs --tail --app campusperks'
|