summaryrefslogtreecommitdiffstats
path: root/.config/nvim/plug-config/vim-lsp.vim
diff options
context:
space:
mode:
authorJoe <rrbo@proton.me>2023-08-31 15:29:51 +0200
committerJoe <rrbo@proton.me>2023-08-31 15:29:51 +0200
commitbade2e137d3fd2861e8323b1a4092b2d343e7b9d (patch)
treed5f839c376425bc5a03e6d3d5044021abbfbc4c9 /.config/nvim/plug-config/vim-lsp.vim
parentup (diff)
downloaddotfiles-bsd-bade2e137d3fd2861e8323b1a4092b2d343e7b9d.tar.gz
dotfiles-bsd-bade2e137d3fd2861e8323b1a4092b2d343e7b9d.tar.bz2
dotfiles-bsd-bade2e137d3fd2861e8323b1a4092b2d343e7b9d.tar.xz
dotfiles-bsd-bade2e137d3fd2861e8323b1a4092b2d343e7b9d.tar.zst
dotfiles-bsd-bade2e137d3fd2861e8323b1a4092b2d343e7b9d.zip
up
Diffstat (limited to '.config/nvim/plug-config/vim-lsp.vim')
-rw-r--r--.config/nvim/plug-config/vim-lsp.vim13
1 files changed, 13 insertions, 0 deletions
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 <buffer> gd <plug>(lsp-definition)
+ "autocmd FileType go nmap <buffer> ,n <plug>(lsp-next-error)
+ "autocmd FileType go nmap <buffer> ,p <plug>(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