23. fugitive
对 git 的完备支持
:Git [args]
:Git! [args]
Run an arbitrary git command. Similar to :!git [args]
but chdir to the repository tree first.
*fugitive-:Git!*
Like |:Git|, but capture the output into a temp file,
and edit that temp file.
:Gcd [directory]
*fugitive-:Gcd*
|:cd| relative to the repository.
:Glcd [directory]
*fugitive-:Glcd*
|:lcd| relative to the repository.
:Gstatus
*fugitive-:Gstatus*
Bring up the output of git-status in the preview
window. The following maps, which work on the cursor
line file where sensible, are provided:
<c-n>
<c-p>
<cr>
cA
ca
cc
cva
cvc
D
ds
dp
dp
dv
O
next file
previous file
|:Gedit|
|:Git| add
|:Git| reset (staged files)
|:Gcommit| --amend --reuse-message=HEAD
|:Gcommit| --amend
|:Gcommit|
|:Gcommit| --amend --verbose
|:Gcommit| --verbose
|:Gdiff|
|:Gsdiff|
|:Git!| diff (p for patch; use :Gw to apply)
|:Git| add --intent-to-add (untracked files)
|:Gvdiff|
|:Gtabedit|