Update IDE like features to be behind variable toggles

Also get's rid of neocomplete in favor of deoplete for vim8 as well and
neocomplecache as a fallback
This commit is contained in:
ViViDboarder 2019-10-21 16:27:34 -07:00
parent 57e5f83dc8
commit 16d6dd2ce5
2 changed files with 23 additions and 22 deletions

View File

@ -32,35 +32,33 @@ if !exists('g:gui_oni')
endif
" }} Searching
" Programming {{
" TODO: Maybe replace with coc.nvim. If I'm doing a lot of development, I will
" have latest versions of vim or nvim
" Only need one fallback, maybe neocomplcache
" Autocomplete {{
call s:smart_source_rc('plugins/omnicompletion')
if exists('g:gui_oni')
if !g:vim_as_an_ide || g:gui.has_autocomplete_features
" We'll keep Oni's autocomplete with Language Server
elseif has('nvim') && has('python3')
elseif (has('nvim') || v:version >= 800) && has('python3')
call s:smart_source_rc('plugins/deoplete')
elseif (has('lua') && (v:version > 703 || v:version == 703 && has('patch885')))
call s:smart_source_rc('plugins/neocomplete')
else
call s:smart_source_rc('plugins/neocomplcache')
end
" }} Autocomplete
" Programming {{
Plug 'tpope/vim-surround'
call s:smart_source_rc('plugins/tagbar')
call s:smart_source_rc('plugins/tcomment_vim')
if (v:version > 703) && !exists('g:gui_oni')
if g:vim_as_an_ide && (v:version > 703) && !g:gui.has_ctags_features
call s:smart_source_rc('plugins/tagbar')
Plug 'ludovicchabant/vim-gutentags' " Auto generate tags files
command! TagsUpdate :GutentagsUpdate<CR>
end
" TODO: Maybe ALE. Similar reason as coc.nvim. Probably only using latest vim
" if developing seriously
if (has('nvim') || v:version >= 800)
if !g:vim_as_an_ide
" Do nothing
elseif (has('nvim') || v:version >= 800)
call s:smart_source_rc('plugins/neomake')
else
call s:smart_source_rc('plugins/syntastic')
@ -69,11 +67,9 @@ endif
" GUI {{
Plug 'gregsexton/MatchTag'
if !exists('g:gui_oni')
call s:smart_source_rc('plugins/airline')
endif
call s:smart_source_rc('plugins/dash')
if !exists('g:gui_oni')
if !g:gui.has_buffer_features
call s:smart_source_rc('plugins/airline')
call s:smart_source_rc('plugins/startify')
endif
" Plug 'edkolev/tmuxline.vim' " Removed because this can fail on some machines
@ -108,18 +104,15 @@ let g:rustfmt_autosave = 1
call s:smart_source_rc('plugins/python')
" }}
" if (v:version > 703)
" Plug 'Yggdroot/indentLine', { 'for': ['python', 'yaml'] }
" endif
" Themes {{
Plug 'altercation/vim-colors-solarized'
Plug 'vim-scripts/vividchalk.vim'
Plug 'vim-scripts/wombat256.vim'
" }}
call s:smart_source_rc('plugins/goyo-limelight') " Distraction free editing
" }}
" System {{
Plug 'tpope/vim-surround'
Plug 'tpope/vim-endwise'
Plug 'tpope/vim-eunuch'
Plug 'tpope/vim-repeat'

View File

@ -1,5 +1,13 @@
" Install plugins
Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
if has('nvim')
Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' }
else
" Vim8 capable layer
Plug 'Shougo/deoplete.nvim'
Plug 'roxma/nvim-yarp'
Plug 'roxma/vim-hug-neovim-rpc'
endif
Plug 'Shougo/neoinclude.vim'
Plug 'Shougo/neco-syntax'
Plug 'zchee/deoplete-jedi', { 'for': 'python' }