Use omni-completion instead of asyncomplete-plug
authorSergey Matveev <stargrave@stargrave.org>
Tue, 14 Jul 2020 08:19:49 +0000 (11:19 +0300)
committerSergey Matveev <stargrave@stargrave.org>
Tue, 14 Jul 2020 08:19:49 +0000 (11:19 +0300)
vim/.vim/plugin/lsp.vim
vim/.vimrc

index 621548b542491a19c5fe41be7b5dcf0879840375..f951f3697eb5dcccad617782fb07456fb16322b7 100644 (file)
@@ -1,12 +1,12 @@
 let g:asyncomplete_auto_completeopt = 0
 let g:asyncomplete_auto_popup = 0
-imap <C-b> <Plug>(asyncomplete_force_refresh)
 
 let g:lsp_highlight_references_enabled = 1
 let g:lsp_diagnostics_echo_cursor = 1
 let g:lsp_diagnostics_echo_delay = -1
 
 function! s:on_lsp_buffer_enabled() abort
+    setlocal omnifunc=lsp#complete
     nmap <buffer> [g <Plug>(lsp-previous-diagnostic)
     nmap <buffer> ]g <Plug>(lsp-next-diagnostic)
     nmap <buffer> gd <plug>(lsp-definition)
index d44abc32fc2118d9092ba9b4a1c1f59373b6c862..dd63405d0ac195dedf4f8ed0d32bafe7161dd880 100644 (file)
@@ -154,6 +154,7 @@ cmap <C-P> <S-Right>
 map Q gq
 map Y y$
 cmap ][ '[,']
+imap <C-b> <C-x><C-o>
 nmap <F2> :set wrap!<CR>:set wrap?<CR>
 nmap <Tab> :buffers<CR>:b<Space>
 nmap <silent> <Home> :registers<CR>