Open :Gcommit tab before current
Pretty ridiculous, but this seems to be the only way to return to the right tab after closing the commit message.
This commit is contained in:
parent
1c844375fa
commit
0fbbe0b3a4
@ -1055,7 +1055,7 @@ function! s:Commit(args, ...) abort
|
|||||||
if bufname('%') == '' && line('$') == 1 && getline(1) == '' && !&mod
|
if bufname('%') == '' && line('$') == 1 && getline(1) == '' && !&mod
|
||||||
execute 'keepalt edit '.s:fnameescape(msgfile)
|
execute 'keepalt edit '.s:fnameescape(msgfile)
|
||||||
elseif a:args =~# '\%(^\| \)-\%(-verbose\|\w*v\)\>'
|
elseif a:args =~# '\%(^\| \)-\%(-verbose\|\w*v\)\>'
|
||||||
execute 'keepalt tabedit '.s:fnameescape(msgfile)
|
execute 'keepalt '.(tabpagenr()-1).'tabedit '.s:fnameescape(msgfile)
|
||||||
elseif s:buffer().type() ==# 'index'
|
elseif s:buffer().type() ==# 'index'
|
||||||
execute 'keepalt edit '.s:fnameescape(msgfile)
|
execute 'keepalt edit '.s:fnameescape(msgfile)
|
||||||
execute (search('^#','n')+1).'wincmd+'
|
execute (search('^#','n')+1).'wincmd+'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user