diff --git a/autoload/fugitive.vim b/autoload/fugitive.vim index a859de9..f442c8e 100644 --- a/autoload/fugitive.vim +++ b/autoload/fugitive.vim @@ -2091,7 +2091,9 @@ function! s:TempReadPost(file) abort if empty(mapcheck('q', 'n')) nnoremap q :bdeleteechohl WarningMsgecho "Temp file q is deprecated in favor of the built-in C-W>q"echohl NONE endif - call s:Map('n', 'gq', ":bdelete", '') + if !&modifiable + call s:Map('n', 'gq', ":bdelete", ' ') + endif endif return '' endfunction