Remove unmerged files on :Gstatus U

This commit is contained in:
Tim Pope 2016-03-09 21:31:25 -05:00
parent 9315ec694d
commit 19d1c944db
2 changed files with 3 additions and 0 deletions

View File

@ -60,6 +60,7 @@ that are part of Git repositories).
U |:Git| checkout
U |:Git| checkout HEAD (staged files)
U |:Git| clean (untracked files)
U |:Git| rm (unmerged files)
*fugitive-:Gcommit*
:Gcommit [args] A wrapper around git-commit. If there is nothing

View File

@ -864,6 +864,8 @@ function! s:StageUndo() abort
if !empty(hash)
if section ==# 'untracked'
call repo.git_chomp_in_tree('clean', '--', filename)
elseif section ==# 'unmerged'
call repo.git_chomp_in_tree('rm', '--', filename)
elseif section ==# 'unstaged'
call repo.git_chomp_in_tree('checkout', '--', filename)
else