aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDuncaen <mail@duncano.de>2015-02-28 16:50:14 +0100
committerDuncaen <mail@duncano.de>2015-02-28 16:50:14 +0100
commit88a34de1209c2362e9cf883492c5f06f5b7fd578 (patch)
treee17158fe7b3f6ea86989c5f4a23600387b88f6d4
parentbb9d6714070db9cd83db846e5cbb7747c49ed889 (diff)
downloaddotfiles-88a34de1209c2362e9cf883492c5f06f5b7fd578.tar.gz
ctrlp: use ag if installed
-rw-r--r--vim/settings/ctrlp.vim8
1 files changed, 8 insertions, 0 deletions
diff --git a/vim/settings/ctrlp.vim b/vim/settings/ctrlp.vim
index e65a5d0..bf352aa 100644
--- a/vim/settings/ctrlp.vim
+++ b/vim/settings/ctrlp.vim
@@ -3,3 +3,11 @@ let g:ctrlp_custom_ignore = {
\ 'dir': '\v[\/]\.(git|hg|svn)$',
\ 'file': '\.pyc$\|\.pyo$\|\.rbc$|\.rbo$\|\.class$\|\.o$\|\~$\',
\ }
+
+" The Silver Searcher
+if executable('ag')
+ " Use ag in CtrlP for listing files. Lightning fast and respects .gitignore
+ let g:ctrlp_user_command = 'ag %s -l --nocolor -g ""'
+ " ag is fast enough that CtrlP doesn't need to cache
+ let g:ctrlp_use_caching = 0
+endif