Act globally when invoking inline diff maps on Head: line

Closes https://github.com/tpope/vim-fugitive/issues/1563
This commit is contained in:
Tim Pope
2021-03-13 19:56:18 -05:00
parent 776ce315c4
commit 3eb6f316c0

View File

@@ -3420,7 +3420,9 @@ function! s:StageInline(mode, ...) abort
endif
let lnum1 = a:0 ? a:1 : line('.')
let lnum = lnum1 + 1
if a:0 > 1 && a:2 == 0
if a:0 > 1 && a:2 == 0 && lnum1 == 1
let lnum = line('$') - 1
elseif a:0 > 1 && a:2 == 0
let info = s:StageInfo(lnum - 1)
if empty(info.paths) && len(info.section)
while len(getline(lnum))