vim: wrap lsp in if has('linux')

This commit is contained in:
Marco Thomas
2023-07-10 16:29:48 +02:00
parent b72f73b985
commit c4242e7608

View File

@@ -25,10 +25,12 @@ Plug 'sainnhe/everforest' " color scheme
Plug 'vim-airline/vim-airline' " nicer status line
Plug 'vim-airline/vim-airline-themes' " auto settings theme for airline
if has('linux')
Plug 'autozimu/LanguageClient-neovim', {
\ 'branch': 'next',
\ 'do': 'bash install.sh',
\ }
endif
call plug#end()
" ============================== Colors
@@ -137,6 +139,7 @@ map <C-M> :messages<CR>
map <C-_> :Commentary<CR>
" ============================== LSP
if has('linux')
set hidden
let g:LanguageClient_serverCommands = {
\ 'rust': ['~/.cargo/bin/rust-analyzer'],
@@ -151,3 +154,4 @@ map <F2> :call LanguageClient#textDocument_rename()<CR>
map <F12> :call LanguageClient#textDocument_definition()<CR>
inoremap <C-space> <C-x><C-o>
imap <C-@> <C-space>
endif