Fix staging hunk that comes after binary file

Closes https://github.com/tpope/vim-fugitive/issues/1462
This commit is contained in:
Tim Pope
2020-03-05 08:34:50 -05:00
parent 8388b6d0fb
commit e06005a742

View File

@@ -3348,6 +3348,8 @@ function! s:StageInline(mode, ...) abort
endif
let start = index
let mode = 'head'
elseif mode ==# 'head' && line =~# '^diff '
let start = index
elseif mode ==# 'head' && substitute(line, "\t$", '', '') ==# '--- ' . info.relative[-1]
let mode = 'await'
elseif mode ==# 'head' && substitute(line, "\t$", '', '') ==# '+++ ' . info.relative[0]