.vim/autoload/vimrc.vim

changeset 862
279abee5d0e8
parent 832
8acb094e5e12
child 864
a36fae082d5f
--- a/.vim/autoload/vimrc.vim
+++ b/.vim/autoload/vimrc.vim
@@ -87,3 +87,12 @@ func! vimrc#SafeFilterFile(cmd)
     call delete(errors)
   endtry
 endfunc
+
+func! vimrc#on_lsp_buffer_enabled() abort
+    setl omnifunc=lsp#complete
+    setl signcolumn=yes
+    nmap <buffer> <F9> <plug>(lsp-hover)
+    nmap <buffer> gd   <plug>(lsp-definition)
+    nmap <buffer> ]d   <plug>(lsp-next-diagnostic)
+    nmap <buffer> [d   <plug>(lsp-previous-diagnostic)
+endfunc

mercurial