iTerm2终端集成git缩写意思

iTerm2终端集成git缩写意思

oh-my-zsh git

git 插件提供了许多别名和一些有用的功能。

在获取 OMZ 之前通过将 git 添加到 plugins 数组来启用它(参见 [[Plugins]])

Aliases

AliasCommand
ggit
gagit add
gaagit add --all
gapagit add --patch
gaugit add --update
gbgit branch
gbagit branch -a
gbdagit branch --merged | command grep -vE “^(|\smaster\s*$)” | command xargs -n 1 git branch -d
gblgit blame -b -w
gbnmgit branch --no-merged
gbrgit branch --remote
gbsgit bisect
gbsbgit bisect bad
gbsggit bisect good
gbsrgit bisect reset
gbssgit bisect start
gcgit commit -v
gc!git commit -v --amend
gcagit commit -v -a
gcamgit commit -a -m
gca!git commit -v -a --amend
gcan!git commit -v -a -s --no-edit --amend
gcbgit checkout -b
gcfgit config --list
gclgit clone --recursive
gcleangit clean -df
gcmgit checkout master
gcdgit checkout develop
gcmsggit commit -m
gcogit checkout
gcountgit shortlog -sn
gcpgit cherry-pick
gcpagit cherry-pick --abort
gcpcgit cherry-pick --continue
gcsgit commit -S
gdgit diff
gdcagit diff --cached
gdtgit diff-tree --no-commit-id --name-only -r
gdwgit diff --word-diff
gfgit fetch
gfagit fetch --all --prune
gfogit fetch origin
gggit gui citool
ggagit gui citool --amend
ggfgit push --force origin $(current_branch)
ghhgit help
ggpullggl
ggpurggu
ggpushggp
ggsupgit branch --set-upstream-to = origin/$(current_branch)
gpsupgit push --set-upstream origin $(current_branch)
gignoregit update-index --assume-unchanged
gignoredgit ls-files -v | grep “1
git-svn-dcommit-pushgit svn dcommit && git push github master:svntrunk
gk\gitk --all --branches
gke\gitk --all $(git log -g --pretty = format:%h)
glgit pull
glggit log --stat --color
glgggit log --graph --color
glggagit log --graph --decorate --all
glgmgit log --graph --max-count = 10
glgpgit log --stat --color -p
glogit log --oneline --decorate --color
gloggit log --oneline --decorate --color --graph
glolgit log --graph --pretty = format:’%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset’ --abbrev-commit
glolagit log --graph --pretty = format:’%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset’ --abbrev-commit --all
glp_git_log_prettily
gmgit merge
gmomgit merge origin/master
gmtgit mergetool --no-prompt
gmtvimgit mergetool --no-prompt --tool = vimdiff
gmumgit merge upstream/master
gpgit push
gpdgit push --dry-run
gpoatgit push origin --all && git push origin --tags
gpristinegit reset --hard && git clean -dfx
gpugit push upstream
gpvgit push -v
grgit remote
gragit remote add
grbgit rebase
grbagit rebase --abort
grbcgit rebase --continue
grbigit rebase -i
grbmgit rebase master
grbsgit rebase --skip
grhgit reset HEAD
grhhgit reset HEAD --hard
grmvgit remote rename
grrmgit remote remove
grsetgit remote set-url
grtcd $(git rev-parse --show-toplevel || echo “.”)
grugit reset –
grupgit remote update
grvgit remote -v
gsbgit status -sb
gsdgit svn dcommit
gsigit submodule init
gspsgit show --pretty = short --show-signature
gsrgit svn rebase
gssgit status -s
gstgit status
gstagit stash save
gstaagit stash apply
gstdgit stash drop
gstlgit stash list
gstpgit stash pop
gstcgit stash clear
gstsgit stash show --text
gsugit submodule update
gtsgit tag -s
gunignoregit update-index --no-assume-unchanged
gunwipgit log -n 1 | grep -q -c “–wip–” && git reset HEAD~1
gupgit pull --rebase
gupvgit pull --rebase -v
glumgit pull upstream master
gvtgit verify-tag
gwchgit whatchanged -p --abbrev-commit --pretty = medium
gwipgit add -A; git rm $(git ls-files --deleted) 2> /dev/null; git commit -m “–wip–”

已废弃的别名

这些别名已被删除、重命名或以其他方式修改。

AliasCommandModification
gapgit add --patchnew alias gapa
gclgit config --listnew alias gcf
gdcgit diff --cachednew alias gdca
gdtgit difftoolno replacement
ggpullgit pull origin $(current_branch)new alias ggl (ggpull still exists for now though)
ggpurgit pull --rebase origin $(current_branch)new alias ggu (ggpur still exists for now though)
ggpushgit push origin $(current_branch)new alias ggp (ggpush still exists for now though)
gkgitk --all --branchesnow aliased to \gitk --all --branches
glggit log --stat --max-count = 10now aliased to git log --stat --color
glgggit log --graph --max-count = 10now aliased to git log --graph --color
gwcgit whatchanged -p --abbrev-commit --pretty = mediumnew alias gwch
gwipgit add -A; git ls-files --deleted -z | xargs -r0 git rm; git commit -m “–wip–”now aliased to git add -A; git rm $(git ls-files --deleted) 2> /dev/null; git commit -m “–wip–”

Current

CommandDescription
current_branchReturn the name of the current branch
current_repositoryReturn the names of the current remotes
git_current_user_nameReturns the user.name config value
git_current_user_emailReturns the user.email config value

Wip

这些功能允许暂停分支开发并切换到另一个分支(“正在进行的工作”,或 wip)。当您想回去工作时,只需将其解开即可。

CommandDescription
work_in_progressEchoes a warning if the current branch is a wip
gwipCommit wip branch
gunwipUncommit wip branch

  1. [:lower:] ↩︎

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值