From bade2e137d3fd2861e8323b1a4092b2d343e7b9d Mon Sep 17 00:00:00 2001 From: Joe Date: Thu, 31 Aug 2023 15:29:51 +0200 Subject: up --- .config/nvim/plug-config/vim-lsp.vim | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to '.config/nvim/plug-config') diff --git a/.config/nvim/plug-config/vim-lsp.vim b/.config/nvim/plug-config/vim-lsp.vim index 03c9d82..fb0d055 100644 --- a/.config/nvim/plug-config/vim-lsp.vim +++ b/.config/nvim/plug-config/vim-lsp.vim @@ -21,6 +21,19 @@ highlight LspWarningHighlight cterm=underline gui=underline ctermfg=DarkRed guif highlight LspInformationHighlight cterm=underline gui=underline ctermfg=Green guifg=Green highlight LspHintHighlight term=italic cterm=italic gui=italic ctermfg=Green guifg=Green +augroup LspGo + au! + autocmd User lsp_setup call lsp#register_server({ + \ 'name': 'go-lang', + \ 'cmd': {server_info->['gopls']}, + \ 'whitelist': ['go'], + \ }) + autocmd FileType go setlocal omnifunc=lsp#complete + "autocmd FileType go nmap gd (lsp-definition) + "autocmd FileType go nmap ,n (lsp-next-error) + "autocmd FileType go nmap ,p (lsp-previous-error) +augroup END + let g:lsp_signs_priority = 10 let g:lsp_textprop_enabled = 1 let g:lsp_cxx_hl_use_text_props = 1 -- cgit v1.2.3