Skip to content

Instantly share code, notes, and snippets.

@jbmyid
Last active December 25, 2015 02:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jbmyid/6900700 to your computer and use it in GitHub Desktop.
Save jbmyid/6900700 to your computer and use it in GitHub Desktop.
Common bash config and aliases for git
function git.branch {
br=`git branch | grep "*"`
echo ${br/* /}
}
function git.pull {
branch=`git.branch`
op=`git pull origin $branch`
}
function git.push {
branch=`git.branch`
op=`git push origin $branch`
}
# Customize to your needs...
[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"
alias dpr='cd ~/JB/Projects/DPR-RE'
alias dpruser='cd ~/JB/Projects/User-DPR'
alias gpl='git pull origin'
alias gps='git push origin'
alias gcb='git checkout -b'
alias gc='git checkout'
alias gs='git status'
alias gcma='git commit -am'
alias gdc='git diff --color'
alias gm='git merge '
alias gpul='git.pull'
alias gpus='git.push'
alias reload=". ~/.zshrc && echo 'ZSH config reloaded from ~/.zshrc'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment