diff --git a/vim/rc/plugins.rc.vim b/vim/rc/plugins.rc.vim index 44f31b7..57802b7 100644 --- a/vim/rc/plugins.rc.vim +++ b/vim/rc/plugins.rc.vim @@ -15,118 +15,84 @@ endfunction " Navigation {{ Plug 'file-line' Plug 'tpope/vim-vinegar' -Plug 'sandeepcr529/Buffet.vim', { 'on': 'Bufferlist' } -" Buffet {{ -nnoremap :Bufferlist -" }} Buffet +call s:smart_source_rc('plugins/Buffet') " }} Navigation " Git {{ -Plug 'tpope/vim-fugitive', { 'on': ['Gblame', 'Gdiff', 'Gcommit', 'Gstatus', 'Gwrite'] } call s:smart_source_rc('plugins/fugitive') -Plug 'airblade/vim-gitgutter', { 'on': ['GitGutterSignsToggle'] } call s:smart_source_rc('plugins/gitgutter') " }} Git - " Searching {{ -Plug 'ctrlpvim/ctrlp.vim' call s:smart_source_rc('plugins/ctrlp') -Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': 'yes \| ./install' } -Plug 'junegunn/fzf.vim' -let g:fzf_command_prefix = 'Fzf' -Plug 'mhinz/vim-grepper' -call s:smart_source_rc('plugins/grepper') -" }} Fuzzy Find +call s:smart_source_rc('plugins/fzf') +call s:smart_source_rc('plugins/incsearch') +call s:smart_source_rc('plugins/vim-grepper') +" }} Searching " Autocomplete {{ call s:smart_source_rc('plugins/omnicompletion') if (has('lua') && (v:version > 703 || v:version == 703 && has('patch885'))) - Plug 'Shougo/neocomplete.vim' call s:smart_source_rc('plugins/neocomplete') elseif has('nvim') && has('python3') - Plug 'Shougo/deoplete.nvim' - Plug 'Shougo/neoinclude.vim' - Plug 'Shougo/neco-syntax' - Plug 'zchee/deoplete-jedi' - Plug 'zchee/deoplete-go' call s:smart_source_rc('plugins/deoplete') - " Remember :UpdateRemotePlugins else - Plug 'Shougo/neocomplcache.vim' call s:smart_source_rc('plugins/neocomplcache') end " }} Autocomplete " Programming {{ -if has('nvim') - Plug 'kassio/neoterm' -endif -Plug 'majutsushi/tagbar' -" tagbar {{ -nnoremap :TagbarToggle -let g:tagbar_autofocus = 1 " Autofocus tagbar -" }} tagbar +Plug 'tpope/vim-surround' +call s:smart_source_rc('plugins/tagbar') +call s:smart_source_rc('plugins/tcomment_vim') if (v:version > 703) Plug 'ludovicchabant/vim-gutentags' " Auto generate tags files end -Plug 'tpope/vim-surround' -Plug 'tomtom/tcomment_vim' " , { 'on': ['TComment', 'TCommentBlock'] } -" tcomment_vim {{ -nnoremap // :TComment -vnoremap // :TCommentBlock -" }} tcomment_vim -if !has('nvim') +if has('nvim') + Plug 'kassio/neoterm' +else " Only use if not neovim, on neovim we have Neomake - Plug 'scrooloose/syntastic' call s:smart_source_rc('plugins/syntastic') endif " }} " GUI {{ -Plug 'mhinz/vim-startify' -call s:smart_source_rc('plugins/startify') +Plug 'gregsexton/MatchTag' Plug 'vim-airline/vim-airline' Plug 'vim-airline/vim-airline-themes' +call s:smart_source_rc('plugins/airline') +call s:smart_source_rc('plugins/dash') +call s:smart_source_rc('plugins/startify') " Plug 'edkolev/tmuxline.vim' " Removed because this can fail on some machines " let g:tmuxline_powerline_separators = 0 -call s:smart_source_rc('plugins/airline') -" Highlight matching tags -Plug 'gregsexton/MatchTag' -" Integrate with Dash -Plug 'rizzatti/dash.vim' -" dash.vim {{ -nmap d DashSearch -let g:dash_map = { - \ 'apex' : 'apex', - \ 'visualforce' : 'vf', - \ } -" }} dash.vim " }} GUI " Filetypes {{ +Plug 'ViViDboarder/force-vim', { 'for': ['apex', 'visualforce'] } Plug 'ViViDboarder/vim-forcedotcom' Plug 'avakhov/vim-yaml' Plug 'dag/vim-fish' Plug 'dart-lang/dart-vim-plugin' +Plug 'fatih/vim-go' Plug 'groovy.vim' Plug 'hsanson/vim-android' -Plug 'udalov/kotlin-vim' Plug 'pangloss/vim-javascript' Plug 'pdurbin/vim-tsv' Plug 'tfnico/vim-gradle' Plug 'tmux-plugins/vim-tmux' -Plug 'fatih/vim-go' -" vim-go { +Plug 'udalov/kotlin-vim' let g:go_def_mapping_enabled = 0 -" } " }} " Python {{ 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 'candy.vim' @@ -139,29 +105,22 @@ Plug 'therubymug/vim-pyte' Plug 'vividchalk.vim' Plug 'wombat256.vim' " }} +call s:smart_source_rc('plugins/goyo-limelight') " Distraction free editing " System {{ + " neomake / vim-dispatch {{ if has('nvim') - Plug 'benekastah/neomake' - nnoremap :Neomake - let g:neomake_python_enabled_makers = ['flake8'] - command! TagsUpdate NeomakeSh ctags -R . + call s:smart_source_rc('plugins/neomake') else - Plug 'tpope/vim-dispatch' - nnoremap :Make - command! TagsUpdate Dispatch ctags -R . + call s:smart_source_rc('plugins/vim-dispatch') endif " }} +" Plug 'Shougo/vimproc.vim', { 'do': 'make' } Plug 'tpope/vim-endwise' Plug 'tpope/vim-eunuch' Plug 'tpope/vim-repeat' -" emacs bindinds in insert -Plug 'tpope/vim-rsi' -Plug 'milkypostman/vim-togglelist' -" vim-togglelist {{ -nnoremap :call ToggleQuickfixList() -nnoremap :call ToggleLocationList() -" }} vim-togglelist +Plug 'tpope/vim-rsi' " emacs bindinds in insert +call s:smart_source_rc('plugins/vim-togglelist') " }} diff --git a/vim/rc/plugins/buffet.rc.vim b/vim/rc/plugins/buffet.rc.vim new file mode 100644 index 0000000..23ee47c --- /dev/null +++ b/vim/rc/plugins/buffet.rc.vim @@ -0,0 +1,2 @@ +Plug 'sandeepcr529/Buffet.vim', { 'on': 'Bufferlist' } +nnoremap :Bufferlist diff --git a/vim/rc/plugins/ctrlp.rc.vim b/vim/rc/plugins/ctrlp.rc.vim index ab24f90..7de0813 100644 --- a/vim/rc/plugins/ctrlp.rc.vim +++ b/vim/rc/plugins/ctrlp.rc.vim @@ -1,4 +1,5 @@ -" Configurationf or ctrlp.vim +Plug 'ctrlpvim/ctrlp.vim' +" Configuration for ctrlp.vim " Ensure max height isn't too large. (for performance) let g:ctrlp_max_height = 10 diff --git a/vim/rc/plugins/dash.rc.vim b/vim/rc/plugins/dash.rc.vim new file mode 100644 index 0000000..f173452 --- /dev/null +++ b/vim/rc/plugins/dash.rc.vim @@ -0,0 +1,8 @@ +" Install plugin +Plug 'rizzatti/dash.vim' +" Set config" +nmap d DashSearch +let g:dash_map = { + \ 'apex' : 'apex', + \ 'visualforce' : 'vf', + \ } diff --git a/vim/rc/plugins/deoplete.rc.vim b/vim/rc/plugins/deoplete.rc.vim index 27bd85c..8673aed 100644 --- a/vim/rc/plugins/deoplete.rc.vim +++ b/vim/rc/plugins/deoplete.rc.vim @@ -1,3 +1,10 @@ +" Install plugins +Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' } +Plug 'Shougo/neoinclude.vim' +Plug 'Shougo/neco-syntax' +Plug 'zchee/deoplete-jedi' +Plug 'zchee/deoplete-go' + inoremap pumvisible() ? "\" : deoplete#mappings#manual_complete() inoremap pumvisible() ? "\" : deoplete#mappings#manual_complete() diff --git a/vim/rc/plugins/fugitive.rc.vim b/vim/rc/plugins/fugitive.rc.vim index 81705d4..2ee2b78 100644 --- a/vim/rc/plugins/fugitive.rc.vim +++ b/vim/rc/plugins/fugitive.rc.vim @@ -1,3 +1,4 @@ +Plug 'tpope/vim-fugitive' ", { 'on': ['Gblame', 'Gdiff', 'Gcommit', 'Gstatus', 'Gwrite'] } " Mappings nnoremap gb :Gblame nnoremap gc :Gcommit diff --git a/vim/rc/plugins/fzf.rc.vim b/vim/rc/plugins/fzf.rc.vim new file mode 100644 index 0000000..a10f83a --- /dev/null +++ b/vim/rc/plugins/fzf.rc.vim @@ -0,0 +1,3 @@ +Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': 'yes \| ./install' } +Plug 'junegunn/fzf.vim' +let g:fzf_command_prefix = 'Fzf' diff --git a/vim/rc/plugins/gitgutter.rc.vim b/vim/rc/plugins/gitgutter.rc.vim index e6ec1aa..cae8274 100644 --- a/vim/rc/plugins/gitgutter.rc.vim +++ b/vim/rc/plugins/gitgutter.rc.vim @@ -1,3 +1,4 @@ +Plug 'airblade/vim-gitgutter', { 'on': ['GitGutterSignsToggle'] } " Settings to keep gitgutter fast let g:gitgutter_enabled = 1 " Will toggle signs when I want them diff --git a/vim/rc/plugins/goyo-limelight.rc.vim b/vim/rc/plugins/goyo-limelight.rc.vim new file mode 100644 index 0000000..89f8b38 --- /dev/null +++ b/vim/rc/plugins/goyo-limelight.rc.vim @@ -0,0 +1,11 @@ +" Both these plugins work well together for distraction free editing +Plug 'junegunn/goyo.vim', { 'on': 'Goyo' } +Plug 'junegunn/limelight.vim', { 'on': 'Limelight' } +function! s:goyo_enter() + Limelight +endfunction +function! s:goyo_leave() + Limelight! +endfunction +autocmd! User GoyoEnter nested call goyo_enter() +autocmd! User GoyoLeave nested call goyo_leave() diff --git a/vim/rc/plugins/incsearch.rc.vim b/vim/rc/plugins/incsearch.rc.vim new file mode 100644 index 0000000..09cc477 --- /dev/null +++ b/vim/rc/plugins/incsearch.rc.vim @@ -0,0 +1,4 @@ +Plug 'haya14busa/incsearch.vim' +map / (incsearch-forward) +map ? (incsearch-backward) +map g/ (incsearch-stay) diff --git a/vim/rc/plugins/neocomplcache.rc.vim b/vim/rc/plugins/neocomplcache.rc.vim index 304c3e8..e5e97d4 100644 --- a/vim/rc/plugins/neocomplcache.rc.vim +++ b/vim/rc/plugins/neocomplcache.rc.vim @@ -1,3 +1,7 @@ +" Install plugins +Plug 'Shougo/neocomplcache.vim' + +" Set configuration let g:neocomplcache_enable_at_startup = 1 let g:neocomplcache_enable_smart_case = 1 let g:neocomplcache_max_list = 10 diff --git a/vim/rc/plugins/neocomplete.rc.vim b/vim/rc/plugins/neocomplete.rc.vim index 8a0c3c1..9683a3a 100644 --- a/vim/rc/plugins/neocomplete.rc.vim +++ b/vim/rc/plugins/neocomplete.rc.vim @@ -1,3 +1,7 @@ +" Install plugins +Plug 'Shougo/neocomplete.vim' + +" Configure plugins let g:acp_enableAtStartup = 0 let g:neocomplete#enable_at_startup = 1 let g:neocomplete#enable_smart_case = 1 diff --git a/vim/rc/plugins/neomake.rc.vim b/vim/rc/plugins/neomake.rc.vim new file mode 100644 index 0000000..7af6e34 --- /dev/null +++ b/vim/rc/plugins/neomake.rc.vim @@ -0,0 +1,4 @@ +Plug 'benekastah/neomake' +nnoremap :Neomake +let g:neomake_python_enabled_makers = ['flake8'] +command! TagsUpdate NeomakeSh ctags -R . diff --git a/vim/rc/plugins/python.rc.vim b/vim/rc/plugins/python.rc.vim index b7dfdff..1d31486 100644 --- a/vim/rc/plugins/python.rc.vim +++ b/vim/rc/plugins/python.rc.vim @@ -12,7 +12,7 @@ let g:jedi#auto_vim_configuration = 0 let g:jedi#completions_enabled = 0 let g:jedi#smart_auto_mappings = 0 " }} jedi-vim -Plug 'klen/python-mode' +Plug 'klen/python-mode', { 'for': 'python' } " python-mode {{ " A lot is disabled, what I'm using: " breakpoints, virtualenv, motions, syntax, diff --git a/vim/rc/plugins/startify.rc.vim b/vim/rc/plugins/startify.rc.vim index 3b90f67..48b420d 100644 --- a/vim/rc/plugins/startify.rc.vim +++ b/vim/rc/plugins/startify.rc.vim @@ -1,3 +1,4 @@ +Plug 'mhinz/vim-startify' let g:startify_list_order = [ \ [' My Bookmarks'], 'bookmarks', \ [' Most recently used files in the current directory'], 'dir', diff --git a/vim/rc/plugins/syntastic.rc.vim b/vim/rc/plugins/syntastic.rc.vim index 91f701c..1c26a76 100644 --- a/vim/rc/plugins/syntastic.rc.vim +++ b/vim/rc/plugins/syntastic.rc.vim @@ -1,3 +1,4 @@ +Plug 'scrooloose/syntastic' if exists('loaded_syntastic') let g:syntastic_html_tidy_ignore_errors = [ \ 'proprietary attribute "ng-show"', diff --git a/vim/rc/plugins/tagbar.rc.vim b/vim/rc/plugins/tagbar.rc.vim new file mode 100644 index 0000000..a8f4f45 --- /dev/null +++ b/vim/rc/plugins/tagbar.rc.vim @@ -0,0 +1,4 @@ +Plug 'majutsushi/tagbar' +nnoremap :TagbarToggle +let g:tagbar_autofocus = 1 " Autofocus tagbar + diff --git a/vim/rc/plugins/tcomment_vim.rc.vim b/vim/rc/plugins/tcomment_vim.rc.vim new file mode 100644 index 0000000..dfe0173 --- /dev/null +++ b/vim/rc/plugins/tcomment_vim.rc.vim @@ -0,0 +1,3 @@ +Plug 'tomtom/tcomment_vim' " , { 'on': ['TComment', 'TCommentBlock'] } +nnoremap // :TComment +vnoremap // :TCommentBlock diff --git a/vim/rc/plugins/vim-dispatch.rc.vim b/vim/rc/plugins/vim-dispatch.rc.vim new file mode 100644 index 0000000..70146d6 --- /dev/null +++ b/vim/rc/plugins/vim-dispatch.rc.vim @@ -0,0 +1,3 @@ +Plug 'tpope/vim-dispatch' +nnoremap :Make +command! TagsUpdate Dispatch ctags -R . diff --git a/vim/rc/plugins/grepper.rc.vim b/vim/rc/plugins/vim-grepper.rc.vim similarity index 95% rename from vim/rc/plugins/grepper.rc.vim rename to vim/rc/plugins/vim-grepper.rc.vim index 9f9224e..bb66f9f 100644 --- a/vim/rc/plugins/grepper.rc.vim +++ b/vim/rc/plugins/vim-grepper.rc.vim @@ -1,3 +1,4 @@ +Plug 'mhinz/vim-grepper' " Grepper settings and shortcuts let g:grepper = { \ 'dispatch': 1, diff --git a/vim/rc/plugins/vim-togglelist.rc.vim b/vim/rc/plugins/vim-togglelist.rc.vim new file mode 100644 index 0000000..584d252 --- /dev/null +++ b/vim/rc/plugins/vim-togglelist.rc.vim @@ -0,0 +1,3 @@ +Plug 'milkypostman/vim-togglelist' +nnoremap :call ToggleQuickfixList() +nnoremap :call ToggleLocationList()