From 454ddb170b92637f74067fdeec115c18456adcbc Mon Sep 17 00:00:00 2001 From: Murukesh Mohanan Date: Sat, 10 Dec 2016 23:51:40 +0900 Subject: [PATCH] switch back to ycm for go --- .vim/autoload/plug.vim | 5 +++-- .vim/spell/en.utf-8.add | 3 +++ .vim/vimrc | 14 +++++++------- 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/.vim/autoload/plug.vim b/.vim/autoload/plug.vim index 7945e8d..d16afe8 100644 --- a/.vim/autoload/plug.vim +++ b/.vim/autoload/plug.vim @@ -225,6 +225,7 @@ function! plug#end() endif call add(s:triggers[name].map, cmd) elseif cmd =~# '^[A-Z]' + let cmd = substitute(cmd, '!*$', '', '') if exists(':'.cmd) != 2 call s:assoc(lod.cmd, cmd, name) endif @@ -251,7 +252,7 @@ function! plug#end() for [cmd, names] in items(lod.cmd) execute printf( - \ 'command! -nargs=* -range -bang %s call s:lod_cmd(%s, "", , , , %s)', + \ 'command! -nargs=* -range -bang -complete=file %s call s:lod_cmd(%s, "", , , , %s)', \ cmd, string(cmd), string(names)) endfor @@ -750,7 +751,7 @@ function! s:prepare(...) for k in ['', 'L', 'o', 'X', 'd', 'dd'] execute 'silent! unmap ' k endfor - setlocal buftype=nofile bufhidden=wipe nobuflisted nolist noswapfile nowrap cursorline modifiable + setlocal buftype=nofile bufhidden=wipe nobuflisted nolist noswapfile nowrap cursorline modifiable nospell setf vim-plug if exists('g:syntax_on') call s:syntax() diff --git a/.vim/spell/en.utf-8.add b/.vim/spell/en.utf-8.add index 63b79e1..d8c3491 100644 --- a/.vim/spell/en.utf-8.add +++ b/.vim/spell/en.utf-8.add @@ -74,3 +74,6 @@ QEMU deduplication ciphertext ciphertexts +filesystem +YJLinux +Kubernetes diff --git a/.vim/vimrc b/.vim/vimrc index 45a701f..129fd90 100644 --- a/.vim/vimrc +++ b/.vim/vimrc @@ -110,9 +110,9 @@ function! YCMInstallCmd() if executable('c++') let l:ycm_cmd .= ' --clang-completer' endif - "if executable('go') - " let l:ycm_cmd .= ' --gocode-completer' - "endif + if executable('go') + let l:ycm_cmd .= ' --gocode-completer' + endif if executable('npm') let l:ycm_cmd .= ' --tern-completer' endif @@ -137,14 +137,14 @@ Plug 'godlygeek/tabular' if executable('cmake') " YCM command lifted from vim-plug readme - Plug 'Valloric/YouCompleteMe', { 'do': YCMInstallCmd(), 'for': ['cpp', 'c', 'sh', 'javascript', 'vim', 'tex'] } + Plug 'Valloric/YouCompleteMe', { 'do': YCMInstallCmd(), 'for': ['cpp', 'c', 'sh', 'javascript', 'vim', 'tex', 'go'] } autocmd! User YouCompleteMe if !has('vim_starting') | call youcompleteme#Enable() | endif endif if executable('go') Plug 'fatih/vim-go', {'for': 'go'} - Plug 'Shougo/neocomplete.vim', {'for': 'go'} - Plug 'Shougo/vimproc.vim', {'do': 'make'} - Plug 'Shougo/echodoc.vim' + "Plug 'Shougo/neocomplete.vim', {'for': 'go'} + "Plug 'Shougo/vimproc.vim', {'do': 'make'} + "Plug 'Shougo/echodoc.vim' endif if executable('latex') Plug 'lervag/vimtex', {'for': 'tex'} -- 2.24.1