summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjohannst <stoelp@eit.uni-kl.de>2018-06-18 21:04:13 +0200
committerjohannst <stoelp@eit.uni-kl.de>2018-06-18 21:04:13 +0200
commit3e1968cf1428d9ddda0fd363aa0c20557b4141b4 (patch)
tree7f09a890825ee986df99b8d1daa213433b30e63f
parentb9ecf2e4621186b7e1daca9176f51d979d0e2866 (diff)
downloaddotfiles-3e1968cf1428d9ddda0fd363aa0c20557b4141b4.tar.gz
dotfiles-3e1968cf1428d9ddda0fd363aa0c20557b4141b4.zip
added fzf vim plugin
-rw-r--r--vimrc25
1 files changed, 24 insertions, 1 deletions
diff --git a/vimrc b/vimrc
index 5626c31..1cc3d58 100644
--- a/vimrc
+++ b/vimrc
@@ -31,12 +31,13 @@ Plugin 'ap/vim-buftabline'
"Plugin 'vim-airline/vim-airline'
"Plugin 'vim-airline/vim-airline-themes'
Plugin 'majutsushi/tagbar'
-Plugin 'ctrlpvim/ctrlp.vim'
+"Plugin 'ctrlpvim/ctrlp.vim'
"Plugin 'vim-scripts/OmniCppComplete'
Plugin 'vim-scripts/YankRing.vim'
Plugin 'johannst/Clever-Tabs'
Plugin 'johannst/AsyncCmdProcessor.vim'
Plugin 'w0rp/ale'
+Plugin 'junegunn/fzf.vim'
call vundle#end()
@@ -152,6 +153,28 @@ if s:IsPluginEnabled('w0rp/ale')
hi link ALESignColumnWithErrors LineNr
endif
+if s:IsPluginEnabled('junegunn/fzf.vim')
+ nnoremap <leader>ft :BTags<CR>
+ nnoremap <leader>fc :Tags<CR>
+ nnoremap <leader>ff :Files<CR>
+ nnoremap <leader>fp :Files
+ "nnoremap <leader>f :CtrlPCurFile<CR>
+ nnoremap <leader>fb :Buffers<CR>
+ nnoremap <leader>fs :History/<CR>
+ let g:fzf_action = { 'ctrl-s': 'split',
+ \ 'ctrl-v': 'vsplit' }
+
+ "imap <c-x><c-f> <plug>(fzf-complete-path)
+
+ command! -bang -nargs=* Rg
+ \ call fzf#vim#grep(
+ \ 'rg --column --line-number --no-heading --color=always '.shellescape(<q-args>), 1,
+ \ <bang>0 ? fzf#vim#with_preview('up:60%')
+ \ : fzf#vim#with_preview('right:50%:hidden', '?'),
+ \ <bang>0)
+ nnoremap <leader>rg :Rg
+endif
+
"}}}
"{{{ Vim Basic