From 9f1b789efd211d1c12bfbc51024528e41027a017 Mon Sep 17 00:00:00 2001 From: Vlad Doster Date: Tue, 31 Dec 2019 23:55:05 -0500 Subject: [PATCH] Added autocompletion for coc-python in vim --- .config/nvim/init.vim | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim index d932cdce..90873baa 100644 --- a/.config/nvim/init.vim +++ b/.config/nvim/init.vim @@ -110,3 +110,19 @@ set clipboard+=unnamedplus autocmd BufWritePost *Xresources,*Xdefaults !xrdb % " Update binds when sxhkdrc is updated. autocmd BufWritePost *sxhkdrc !pkill -USR1 sxhkd +" coc stuff +" You will have bad experience for diagnostic messages when it's default 4000. +set updatetime=300 + +" Autocomplete with control space, similiar to Pycharm +inoremap coc#refresh() + +" Use `:Format` to format current buffer +command! -nargs=0 Format :call CocAction('format') + +" Use `:Fold` to fold current buffer +command! -nargs=? Fold :call CocAction('fold', ) + +" use `:OR` for organize import of current buffer +command! -nargs=0 OR :call CocAction('runCommand', 'editor.action.organizeImport') +