From f601d345f9185eb669bf3845940763a3f7eb3375 Mon Sep 17 00:00:00 2001 From: ItsDrike Date: Wed, 15 Sep 2021 18:47:58 +0200 Subject: [PATCH] Use coc for language IntelliSense completions --- home/.config/nvim/rc/coc.vim | 1 + home/.config/nvim/rc/plugins.d/coc.vim | 1 + home/.config/nvim/rc/plugins.d/python.vim | 12 ------------ home/.config/nvim/rc/plugins.vim | 8 +++----- 4 files changed, 5 insertions(+), 17 deletions(-) create mode 100644 home/.config/nvim/rc/coc.vim create mode 100644 home/.config/nvim/rc/plugins.d/coc.vim delete mode 100644 home/.config/nvim/rc/plugins.d/python.vim diff --git a/home/.config/nvim/rc/coc.vim b/home/.config/nvim/rc/coc.vim new file mode 100644 index 0000000..6d306f9 --- /dev/null +++ b/home/.config/nvim/rc/coc.vim @@ -0,0 +1 @@ +let g:coc_global_extensions = ['coc-python', 'coc-json', 'coc-git', 'coc-html', 'coc-css', 'coc-clangd', 'coc-cmake', 'coc-java', 'coc-sh', 'coc-toml', 'coc-yaml', 'coc-omnisharp'] diff --git a/home/.config/nvim/rc/plugins.d/coc.vim b/home/.config/nvim/rc/plugins.d/coc.vim new file mode 100644 index 0000000..8378ff3 --- /dev/null +++ b/home/.config/nvim/rc/plugins.d/coc.vim @@ -0,0 +1 @@ +let g:coc_global_extensions = ['coc-python', 'coc-json', 'coc-git', 'coc-html', 'coc-css'] diff --git a/home/.config/nvim/rc/plugins.d/python.vim b/home/.config/nvim/rc/plugins.d/python.vim deleted file mode 100644 index 0df3054..0000000 --- a/home/.config/nvim/rc/plugins.d/python.vim +++ /dev/null @@ -1,12 +0,0 @@ -" Define python-specific neomake config -" Neomake is python syntax checker, in this case, we use flake8 -" Requires: pip install flake8 -let g:neomake_python_enabled_makers = ['flake8'] -let g:neomake_python_flake8_maker = {'args': ['--ignore=E501', '--format=default']} -call neomake#configure#automake('nrwi', 500) - -" Enable deoplete on startup -" Deoplete provides autosuggestions from python standard library -" Requires: pip install pynvim -let g:deoplete#enable_at_startup = 1 - diff --git a/home/.config/nvim/rc/plugins.vim b/home/.config/nvim/rc/plugins.vim index 87175e0..b31205f 100644 --- a/home/.config/nvim/rc/plugins.vim +++ b/home/.config/nvim/rc/plugins.vim @@ -14,16 +14,13 @@ endif call plug#begin(config_dir."/plugged") " Code completion -Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' } +Plug 'neoclide/coc.nvim', {'branch': 'release'} " Themes Plug 'tomasiser/vim-code-dark' Plug 'vim-airline/vim-airline' Plug 'vim-airline/vim-airline-themes' Plug 'ryanoasis/vim-devicons' Plug 'airblade/vim-gitgutter' -" Python -Plug 'neomake/neomake' -Plug 'zchee/deoplete-jedi' " Misc Plug 'dhruvasagar/vim-table-mode' Plug 'vimwiki/vimwiki' @@ -40,4 +37,5 @@ let plugins_rc_dir = rc_dir."/plugins.d" execute "source ".plugins_rc_dir."/airline.vim" execute "source ".plugins_rc_dir."/nerdtree.vim" execute "source ".plugins_rc_dir."/vimwiki.vim" -execute "source ".plugins_rc_dir."/python.vim" +execute "source ".plugins_rc_dir."/coc.vim" +"execute "source ".plugins_rc_dir."/python.vim"