Skip to content

Instantly share code, notes, and snippets.

@brandonroberts
Last active November 28, 2019 02:47
Show Gist options
  • Save brandonroberts/bc704c72dc476d9287cd66a85b6a0290 to your computer and use it in GitHub Desktop.
Save brandonroberts/bc704c72dc476d9287cd66a85b6a0290 to your computer and use it in GitHub Desktop.
Git Aliases
alias gch='git checkout'
alias gcb='git checkout -b'
alias gcm='git checkout master'
alias greb='git rebase'
alias grbm='git rebase master'
alias grbc='git rebase --continue'
alias gpl='git pull --ff'
alias gbr='git branch'
alias gpo='git push origin'
alias gdff='git diff'
alias gdfm='git diff master'
alias gadd='git add'
alias gcom='git commit'
alias gagcoma='git add . && git commit --amend'
alias gcmf='git commit --fixup'
alias gfet='git fetch --progress'
alias gpob='git push origin `git rev-parse --abbrev-ref HEAD`'
alias gpofb='git push origin --force-with-lease `git rev-parse --abbrev-ref HEAD`'
alias gs='git status'
alias glog='git log --graph --oneline --decorate --remotes --branches -n 25'
alias glg='git log --oneline'
alias cd1='cd ..'
alias cd2='cd ../../'
alias cd3='cd ../../../'
alias srbc='source ~/.bashrc'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment