From c2fc01fa58b6de16309cf325f045262c50ab9139 Mon Sep 17 00:00:00 2001 From: Justin Giancola Date: Sun, 6 Dec 2020 00:37:37 -0500 Subject: [PATCH] Ignore .git for rg searches (#3996) --- autoload/SpaceVim/plugins/searcher.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/autoload/SpaceVim/plugins/searcher.vim b/autoload/SpaceVim/plugins/searcher.vim index be9e88699..bf0d59513 100644 --- a/autoload/SpaceVim/plugins/searcher.vim +++ b/autoload/SpaceVim/plugins/searcher.vim @@ -55,7 +55,7 @@ function! s:get_search_cmd(exe, expr) abort if a:exe ==# 'grep' return ['grep', '-inHR', '--exclude-dir', '.git', a:expr, '.'] elseif a:exe ==# 'rg' - return ['rg', '--hidden', '--no-heading', '--color=never', '--with-filename', '--line-number', a:expr, '.'] + return ['rg', '-g!.git', '--hidden', '--no-heading', '--color=never', '--with-filename', '--line-number', a:expr, '.'] else return [a:exe, a:expr] endif