vim:plugs: Redefine :Rg to include hidden files

This commit is contained in:
2022-08-30 14:31:37 +02:00
parent 165b0ee7af
commit 4af065f1fd

View File

@@ -26,3 +26,11 @@ if (exists("g:loaded_tmux_navigator"))
" Disable tmux navigator when zooming the Vim pane
let g:tmux_navigator_disable_when_zoomed = 1
endif
if (get(g:, 'loaded_fzf'))
" Redefine :Rg to include hidden files (except for .git)
command! -bang -nargs=* Rg
\ call fzf#vim#grep(
\ 'rg --column --line-number --no-heading --color=always --smart-case --hidden -g "!.git" -- '.shellescape(<q-args>), 1,
\ fzf#vim#with_preview(), <bang>0)
endif