Switch to fzf, remove vim-ripgrep

This commit is contained in:
Rob Watson 2021-03-09 20:40:10 +01:00
parent f78e30c7ed
commit eb071660a1
2 changed files with 12 additions and 19 deletions

View File

@ -20,8 +20,14 @@ nnoremap <silent> dq :GoDebugStop<cr>
nnoremap <silent> dn :GoDebugNext<cr> nnoremap <silent> dn :GoDebugNext<cr>
nnoremap <silent> ds :GoDebugStep<cr> nnoremap <silent> ds :GoDebugStep<cr>
" fzf configuration:
let g:fzf_action = {
\ 'ctrl-t': 'tab split',
\ 'ctrl-x': 'split',
\ 'ctrl-v': 'vsplit' }
" Vim-Go configuration: " Vim-Go configuration:
let g:go_decls_mode = 'skim' let g:go_decls_mode = 'fzf'
let g:go_fmt_autosave = 0 let g:go_fmt_autosave = 0
" Vim-Go seems to handle fix-on-save better than ALE: " Vim-Go seems to handle fix-on-save better than ALE:
let g:go_imports_autosave = 1 let g:go_imports_autosave = 1

23
vimrc
View File

@ -124,19 +124,6 @@ endfunction
nmap <silent> <leader>q :call ToggleQuickFix()<cr> nmap <silent> <leader>q :call ToggleQuickFix()<cr>
nmap <silent> <leader>l :lclose<cr> nmap <silent> <leader>l :lclose<cr>
" vim-ripgrep configuration:
let g:rg_highlight = 1
function RequestGrep()
call inputsave()
let s:pattern = trim(input("grep: "))
call inputrestore()
if len(s:pattern) > 0
execute 'Rg' s:pattern
endif
endfunction
map <Leader>* :call RequestGrep()<CR>
map <Leader>8 :call RequestGrep()<CR>
" deoplete configuration " deoplete configuration
packadd! deoplete.nvim packadd! deoplete.nvim
let g:deoplete#enable_at_startup = 1 let g:deoplete#enable_at_startup = 1
@ -157,9 +144,10 @@ inoremap <expr><C-]> pumvisible() ? "\<C-]>" : "\<Enter>"
" vim-markdown configuration: " vim-markdown configuration:
let g:vim_markdown_conceal = 1 let g:vim_markdown_conceal = 1
" Skim configuration: " fzf configuration:
nmap <leader>t :GFiles<cr> nmap <leader>t :GFiles<cr>
nmap <leader>b :Buffers<cr> nmap <leader>b :Buffers<cr>
nmap <leader>gg :Rg<cr>
" Lightline configuration: " Lightline configuration:
set laststatus=2 set laststatus=2
@ -265,11 +253,10 @@ packadd! lightline.vim
packadd! tmux-complete.vim packadd! tmux-complete.vim
packadd! vim-commentary packadd! vim-commentary
packadd! vim-gitgutter packadd! vim-gitgutter
" Requires both skim.vim plugin to be manually installed: " Requires both fzf.vim plugin to be manually installed:
" https://github.com/lotabout/skim/blob/master/plugin/skim.vim " https://github.com/junegunn/fzf/blob/master/plugin/fzf.vim
" and also this separate plugin, which is loaded here: " and also this separate plugin, which is loaded here:
" https://github.com/lotabout/skim.vim/blob/master/autoload/fzf/vim.vim packadd! fzf.vim
packadd! skim.vim
packadd! vim-go packadd! vim-go
packadd! vim-surround packadd! vim-surround
packadd! vim-yaml-folds packadd! vim-yaml-folds