Don't try to reuse terminal buffers for status window edits

Closes https://github.com/tpope/vim-fugitive/issues/1652
This commit is contained in:
Tim Pope
2021-03-11 01:36:21 -05:00
parent 4fa53ad329
commit d0e277c7be

View File

@@ -4448,7 +4448,7 @@ function! s:UsableWin(nr) abort
return a:nr && !getwinvar(a:nr, '&previewwindow') && !getwinvar(a:nr, '&winfixwidth') && return a:nr && !getwinvar(a:nr, '&previewwindow') && !getwinvar(a:nr, '&winfixwidth') &&
\ (empty(getwinvar(a:nr, 'fugitive_status')) || getbufvar(winbufnr(a:nr), 'fugitive_type') !=# 'index') && \ (empty(getwinvar(a:nr, 'fugitive_status')) || getbufvar(winbufnr(a:nr), 'fugitive_type') !=# 'index') &&
\ index(['gitrebase', 'gitcommit'], getbufvar(winbufnr(a:nr), '&filetype')) < 0 && \ index(['gitrebase', 'gitcommit'], getbufvar(winbufnr(a:nr), '&filetype')) < 0 &&
\ index(['nofile','help','quickfix'], getbufvar(winbufnr(a:nr), '&buftype')) < 0 \ index(['nofile','help','quickfix', 'terminal'], getbufvar(winbufnr(a:nr), '&buftype')) < 0
endfunction endfunction
function! s:OpenParse(args, wants_cmd) abort function! s:OpenParse(args, wants_cmd) abort