Focus quickfix list after :Ggrep! -q

This just feels right.  If we're not jumping to a file, we probably want
to scroll the list.
This commit is contained in:
Tim Pope
2021-08-23 02:59:09 -04:00
parent 5c39cde202
commit 8cdb51622f

View File

@@ -5376,7 +5376,7 @@ function! s:GrepSubcommand(line1, line2, range, bang, mods, options) abort
if quiet if quiet
let bufnr = bufnr('') let bufnr = bufnr('')
silent exe substitute(s:Mods(a:mods), '\<tab\>', '', '') (listnr < 0 ? 'c' : 'l').'open' silent exe substitute(s:Mods(a:mods), '\<tab\>', '', '') (listnr < 0 ? 'c' : 'l').'open'
if bufnr != bufnr('') if bufnr != bufnr('') && !a:bang
wincmd p wincmd p
endif endif
end end