mirror of
https://github.com/donovanglover/nix-config.git
synced 2025-06-20 01:38:02 +02:00
vim: Remove coc.nvim
I never use this and it was actually making tab not work when at the end of of a word. Getting rid of it entirely means less running code that I have to maintain.
This commit is contained in:
parent
a4654beb2b
commit
b7002980f8
57
vim/.vimrc
57
vim/.vimrc
@ -28,7 +28,6 @@ call plug#begin('~/.vim/plugged')
|
|||||||
Plug 'reedes/vim-pencil' " Word wrap
|
Plug 'reedes/vim-pencil' " Word wrap
|
||||||
Plug 'junegunn/goyo.vim' " Distraction-free writing
|
Plug 'junegunn/goyo.vim' " Distraction-free writing
|
||||||
Plug 'jparise/vim-graphql' " GraphQL support
|
Plug 'jparise/vim-graphql' " GraphQL support
|
||||||
Plug 'neoclide/coc.nvim', {'branch': 'release'} " Auto-complete support
|
|
||||||
Plug 'ryanoasis/vim-devicons'
|
Plug 'ryanoasis/vim-devicons'
|
||||||
|
|
||||||
Plug 'osyo-manga/vim-over'
|
Plug 'osyo-manga/vim-over'
|
||||||
@ -298,59 +297,3 @@ let NERDTreeStatusline='%{exists("b:NERDTree")?fnamemodify(b:NERDTree.root.path.
|
|||||||
autocmd! FileType fzf
|
autocmd! FileType fzf
|
||||||
autocmd FileType fzf set laststatus=0 noshowmode noruler
|
autocmd FileType fzf set laststatus=0 noshowmode noruler
|
||||||
\| autocmd BufLeave <buffer> set laststatus=2 ruler
|
\| autocmd BufLeave <buffer> set laststatus=2 ruler
|
||||||
|
|
||||||
" ============================
|
|
||||||
" ========= coc.nvim =========
|
|
||||||
" ============================
|
|
||||||
|
|
||||||
" Some servers have issues with backup files, see #649.
|
|
||||||
set nobackup
|
|
||||||
set nowritebackup
|
|
||||||
|
|
||||||
" Give more space for displaying messages.
|
|
||||||
set cmdheight=2
|
|
||||||
|
|
||||||
" Having longer updatetime (default is 4000 ms = 4 s) leads to noticeable
|
|
||||||
" delays and poor user experience.
|
|
||||||
set updatetime=300
|
|
||||||
|
|
||||||
" Don't pass messages to |ins-completion-menu|.
|
|
||||||
set shortmess+=c
|
|
||||||
|
|
||||||
" Always show the signcolumn, otherwise it would shift the text each time
|
|
||||||
" diagnostics appear/become resolved.
|
|
||||||
set signcolumn=yes
|
|
||||||
|
|
||||||
" GoTo code navigation.
|
|
||||||
nmap <silent> gd <Plug>(coc-definition)
|
|
||||||
nmap <silent> gy <Plug>(coc-type-definition)
|
|
||||||
nmap <silent> gi <Plug>(coc-implementation)
|
|
||||||
nmap <silent> gr <Plug>(coc-references)
|
|
||||||
|
|
||||||
" Use K to show documentation in preview window.
|
|
||||||
nnoremap <silent> K :call <SID>show_documentation()<CR>
|
|
||||||
|
|
||||||
function! s:show_documentation()
|
|
||||||
if (index(['vim','help'], &filetype) >= 0)
|
|
||||||
execute 'h '.expand('<cword>')
|
|
||||||
elseif (coc#rpc#ready())
|
|
||||||
call CocActionAsync('doHover')
|
|
||||||
else
|
|
||||||
execute '!' . &keywordprg . " " . expand('<cword>')
|
|
||||||
endif
|
|
||||||
endfunction
|
|
||||||
|
|
||||||
" Use tab for trigger completion with characters ahead and navigate.
|
|
||||||
" NOTE: Use command ':verbose imap <tab>' to make sure tab is not mapped by
|
|
||||||
" other plugin before putting this into your config.
|
|
||||||
function! s:check_back_space() abort
|
|
||||||
let col = col('.') - 1
|
|
||||||
return !col || getline('.')[col - 1] =~ '\s'
|
|
||||||
endfunction
|
|
||||||
|
|
||||||
" Insert <tab> when previous text is space, refresh completion if not.
|
|
||||||
inoremap <silent><expr> <TAB>
|
|
||||||
\ coc#pum#visible() ? coc#pum#next(1):
|
|
||||||
\ <SID>check_back_space() ? "\<Tab>" :
|
|
||||||
\ coc#refresh()
|
|
||||||
inoremap <expr><S-TAB> coc#pum#visible() ? coc#pum#prev(1) : "\<C-h>"
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user