123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- # Aliases
- alias g=
- compdef g=git
- alias gst=
- compdef _git gst=git-status
- alias gl=
- compdef _git gl=git-pull
- alias gup=
- compdef _git gup=git-fetch
- alias gp=
- compdef _git gp=git-push
- gdv() { git diff -w "$@" | view - }
- compdef _git gdv=git-diff
- alias gc=
- compdef _git gc=git-commit
- alias gca=
- compdef _git gca=git-commit
- alias gco=
- compdef _git gco=git-checkout
- alias gcm=
- alias gb=
- compdef _git gb=git-branch
- alias gba=
- compdef _git gba=git-branch
- alias gcount=
- compdef gcount=git
- alias gcp=
- compdef _git gcp=git-cherry-pick
- alias glg=
- compdef _git glg=git-log
- alias glgg=
- compdef _git glgg=git-log
- alias gss=
- compdef _git gss=git-status
- alias ga=
- compdef _git ga=git-add
- alias gm=
- compdef _git gm=git-merge
- alias grh=
- alias grhh=
- # Git and svn mix
- alias git-svn-dcommit-push=
- compdef git-svn-dcommit-push=git
- alias gsr=
- alias gsd=
- #
- # Will return the current branch name
- # Usage example: git pull origin $(current_branch)
- #
- function current_branch() {
- ref=$(git symbolic-ref HEAD 2> /dev/null) || return
- echo ${ref#refs/heads/}
- }
- # these aliases take advantage of the previous function
- alias ggpull=
- compdef ggpull=git
- alias ggpush=
- compdef ggpush=git
- alias ggpnp=
- compdef ggpnp=git
|