Added LanguageClient

This commit is contained in:
Oliver Hartmann 2018-12-22 21:10:28 +01:00
parent d3010572af
commit 074f5606d9

View File

@ -11,6 +11,17 @@ Plug 'Shougo/neosnippet.vim'
Plug 'honza/vim-snippets' Plug 'honza/vim-snippets'
Plug 'vim-scripts/a.vim' Plug 'vim-scripts/a.vim'
Plug 'luochen1990/rainbow' Plug 'luochen1990/rainbow'
if has("win32")
Plug 'autozimu/LanguageClient-neovim', {
\ 'branch': 'next',
\ 'do': 'powershell -executionpolicy bypass -File install.ps1',
\ }
else
Plug 'autozimu/LanguageClient-neovim', {
\ 'branch': 'next',
\ 'do': 'bash install.sh',
\ }
end
call plug#end() call plug#end()
" =============Settings================== " =============Settings==================
filetype plugin on filetype plugin on
@ -122,3 +133,11 @@ let g:rainbow_conf = {
\} \}
\} \}
" ===================LanguageServer==================
let g:LanguageClient_serverCommands = {
\ 'cpp': ['clangd'],
\ }
nnoremap <silent> K :call LanguageClient#textDocument_hover()<CR>
nnoremap <silent> gd :call LanguageClient#textDocument_definition()<CR>
nnoremap <silent> <F3> :call LanguageClient_contextMenu()<CR>
vnoremap <silent> <F3> :call LanguageClient_contextMenu()<CR>