Skip to content

Instantly share code, notes, and snippets.

@matiss
Created August 18, 2012 21:34
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save matiss/3390028 to your computer and use it in GitHub Desktop.
Save matiss/3390028 to your computer and use it in GitHub Desktop.
Git aliases
alias gd="git diff | subl"
alias ga="git add"
alias gbd="git branch -D"
alias gst="git status"
alias gca="git commit -a -m"
alias gm="git merge --no-ff"
alias gpt="git push --tags"
alias gp="git push"
alias gpo="git push origin"
alias grh="git reset --hard"
alias gb="git branch"
alias gcob="git checkout -b"
alias gco="git checkout"
alias gba="git branch -a"
alias gcp="git cherry-pick"
alias gls="git log -C --stat --decorate"
alias glsp="git log -C --stat -p --decorate"
alias gl="git log --pretty='format:%Cgreen%h%Creset %an - %s' --graph"
alias glsd="git log --graph '--pretty=tformat:%Cblue%h%Creset %Cgreen%ar%Creset %Cblue%d%Creset %s' --all --simplify-by-decoration"
alias gpom="git pull origin master"
alias gpro="git pull --rebase origin"
alias gcd='cd "`git rev-parse --show-toplevel`"'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment