VIM: Update Plugins
This commit is contained in:
parent
db7a295dc3
commit
4914f5df05
@ -101,16 +101,24 @@ set shortmess+=c
|
|||||||
let g:coc_filetype_map = {'tex': 'latex'}
|
let g:coc_filetype_map = {'tex': 'latex'}
|
||||||
" Use tab for trigger completion with characters ahead and navigate.
|
" Use tab for trigger completion with characters ahead and navigate.
|
||||||
" Use command ':verbose imap <tab>' to make sure tab is not mapped by other plugin.
|
" Use command ':verbose imap <tab>' to make sure tab is not mapped by other plugin.
|
||||||
|
|
||||||
|
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>
|
inoremap <silent><expr> <TAB>
|
||||||
\ pumvisible() ? "\<C-n>" :
|
\ coc#pum#visible() ? coc#pum#next(1):
|
||||||
\ <SID>check_back_space() ? "\<TAB>" :
|
\ <SID>check_back_space() ? "\<Tab>" :
|
||||||
\ coc#refresh()
|
\ coc#refresh()
|
||||||
inoremap <expr><S-TAB> pumvisible() ? "\<C-p>" : "\<C-h>"
|
inoremap <expr><S-TAB> coc#pum#visible() ? coc#pum#prev(1) : "\<C-h>"
|
||||||
|
|
||||||
function! s:check_back_space() abort
|
function! s:check_back_space() abort
|
||||||
let col = col('.') - 1
|
let col = col('.') - 1
|
||||||
return !col || getline('.')[col - 1] =~# '\s'
|
return !col || getline('.')[col - 1] =~# '\s'
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
" Use <c-space> to trigger completion.
|
" Use <c-space> to trigger completion.
|
||||||
inoremap <silent><expr> <c-space> coc#refresh()
|
inoremap <silent><expr> <c-space> coc#refresh()
|
||||||
|
|
||||||
|
@ -54,7 +54,7 @@ Plug 'ryanoasis/vim-devicons'
|
|||||||
Plug 'xuhdev/singlecompile'
|
Plug 'xuhdev/singlecompile'
|
||||||
|
|
||||||
" Autocomplete
|
" Autocomplete
|
||||||
Plug 'neoclide/coc.nvim', {'branch': 'release'}
|
Plug 'neoclide/coc.nvim', {'tag': 'v0.0.82'}
|
||||||
Plug 'honza/vim-snippets'
|
Plug 'honza/vim-snippets'
|
||||||
|
|
||||||
" Language Specific stuff (Language Plugins, Linters, etc)
|
" Language Specific stuff (Language Plugins, Linters, etc)
|
||||||
|
Loading…
Reference in New Issue
Block a user