mirror of
https://github.com/tpope/vim-fugitive.git
synced 2025-11-14 06:13:51 -05:00
Improve weird :Ggrep --column quickfix title
This commit is contained in:
@@ -4190,14 +4190,13 @@ function! s:GrepSubcommand(line1, line2, range, bang, mods, options) abort
|
|||||||
let args = args[1:-1]
|
let args = args[1:-1]
|
||||||
endif
|
endif
|
||||||
let name_only = s:HasOpt(args, '-l', '--files-with-matches', '--name-only', '-L', '--files-without-match')
|
let name_only = s:HasOpt(args, '-l', '--files-with-matches', '--name-only', '-L', '--files-without-match')
|
||||||
let title = [listnr < 0 ? ':Ggrep' : ':Glgrep'] + args
|
|
||||||
if listnr > 0
|
if listnr > 0
|
||||||
exe listnr 'wincmd w'
|
exe listnr 'wincmd w'
|
||||||
else
|
else
|
||||||
call s:BlurStatus()
|
call s:BlurStatus()
|
||||||
endif
|
endif
|
||||||
redraw
|
redraw
|
||||||
call s:QuickfixCreate(listnr, {'title': (listnr < 0 ? ':Ggrep ' : ':Glgrep ') . s:fnameescape(args)})
|
call s:QuickfixCreate(listnr, {'title': (listnr < 0 ? ':Git grep ' : ':0Git grep ') . s:fnameescape(args)})
|
||||||
let tempfile = tempname()
|
let tempfile = tempname()
|
||||||
let event = listnr < 0 ? 'grep-fugitive' : 'lgrep-fugitive'
|
let event = listnr < 0 ? 'grep-fugitive' : 'lgrep-fugitive'
|
||||||
silent exe s:DoAutocmd('QuickFixCmdPre ' . event)
|
silent exe s:DoAutocmd('QuickFixCmdPre ' . event)
|
||||||
|
|||||||
Reference in New Issue
Block a user