Skip to content

Instantly share code, notes, and snippets.

@df-jablan
Created February 4, 2016 21:57
Show Gist options
  • Save df-jablan/eb55438c7690ae0ee99e to your computer and use it in GitHub Desktop.
Save df-jablan/eb55438c7690ae0ee99e to your computer and use it in GitHub Desktop.
I ♥ Aliases | ba/sh aliases for git/git-flow | Please source responsibly
#!/bin/bash
######################################################################
## Git Aliases
######################################################################
alias glog='git log --name-only'
alias gb='git branch --list -v'
alias gcm='git checkout master'
alias gcd='git checkout develop'
alias gco='git checkout'
alias gcom='git commit -m '
alias gcu="gac 'Composer dependencies updated.'"
alias gcup='gcu && git push'
alias gacp='gac && git push -q'
alias gpm='git checkout master; git pull'
alias gpd='git checkout develop; git pull'
alias gpl='git pull'
alias gph='git push'
alias gup='gpm ; gpd'
alias gst='git status'
alias gpa='git push --all ; git push --tags ;'
alias gru='git remote update'
alias grs='gru && gst && gb'
alias grsp='grs && gup'
## git-flow aliases
alias gfrs='git flow release start '
alias gfrf='git flow release finish '
alias gfr='git flow release start "$1"; git flow release finish "$1"'
## cd back to the .git root from any subdirectory beneath the root
alias gr='[ ! -z `git rev-parse --show-cdup` ] && cd `git rev-parse --show-cdup || pwd`'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment