Skip to content

Instantly share code, notes, and snippets.

@letanure
Forked from hugooliveirad/git-aliases.sh
Created February 28, 2014 05:45
Show Gist options
  • Save letanure/9265944 to your computer and use it in GitHub Desktop.
Save letanure/9265944 to your computer and use it in GitHub Desktop.
# Mais usados --
alias ga="git add"
alias gc="git commit -m"
alias gca="git commit -am"
alias gs="git status"
alias gp="git push"
alias gpl="git pull"
# Diff --
alias gd="git diff"
alias gds="git diff --staged" # diff apenas nos arquivos que estão no stage
alias gdh="git diff HEAD~1" # compara arquivos atuais com o último commit
# Log --
alias gl="git log"
# Log bonito e com gráficos
alias glp="git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit"
# Outros --
alias gpo="git push origin master"
alias gplo="git pull origin master"
alias gf="git fetch"
alias gr="git remote -v"
alias gco="git checkout"
alias grh="git reset HEAD"
alias gm="git merge"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment