]> Git — Sourcephile - julm/julm-nix.git/blob - homes/softwares/vim/LanguageClient.vim
patate: add backup
[julm/julm-nix.git] / homes / softwares / vim / LanguageClient.vim
1 let g:LanguageClient_autoStart = 1
2 let g:LanguageClient_serverCommands = {
3 \ 'haskell': ['hie-wrapper', '--lsp']
4 \ }
5 let g:LanguageClient_rootMarkers = {
6 \ 'haskell': ['*.cabal', 'stack.yaml'],
7 \ }
8 "let g:LanguageClient_devel = 1
9 "let $LANGUAGECLIENT_DEBUG=1
10 "let g:LanguageClient_loggingLevel = 'DEBUG'
11 nmap <leader>ld :call LanguageClient_textDocument_definition()<CR>
12 nmap <leader>lr :call LanguageClient_textDocument_rename()<CR>
13 nmap <leader>lf :call LanguageClient_textDocument_formatting()<CR>
14 nmap <leader>lt :call LanguageClient_textDocument_typeDefinition()<CR>
15 nmap <leader>lx :call LanguageClient_textDocument_references()<CR>
16 nmap <leader>la :call LanguageClient_textDocument_codeAction()<CR>
17 nmap <leader>lA :call LanguageClient_workspace_applyEdit()<CR>
18 nmap <leader>lc :call LanguageClient_textDocument_completion()<CR>
19 nmap <leader>lh :call LanguageClient_textDocument_hover()<CR>
20 nmap <leader>le :call LanguageClient_explainErrorAtPoint()<CR>
21 nmap <leader>ls :call LanguageClient_textDocument_documentSymbol()<CR>
22 nmap <leader>lm :call LanguageClient_contextMenu()<CR>
23 augroup LanguageClient_config
24 autocmd!
25 autocmd User LanguageClientStarted
26 \ setlocal signcolumn=yes |
27 \ setlocal formatexpr=LanguageClient_textDocument_rangeFormatting_sync() |
28 \ setlocal completefunc=LanguageClient#complete
29 autocmd User LanguageClientStopped
30 \ setlocal signcolumn=auto |
31 \ setlocal signcolumn=auto |
32 \ setlocal formatexpr=
33 augroup END
34 let g:LanguageClient_changeThrottle = 0.5
35 let g:LanguageClient_diagnosticsList = "Quickfix"
36 let g:LanguageClient_diagnosticsMaxSeverity = 'Hint'
37 let g:LanguageClient_hoverPreview = 'Auto'
38 let g:LanguageClient_loadSettings = 1
39 let g:LanguageClient_selectionUI = "quickfix"
40 let g:LanguageClient_selectionUI_autoOpen = 1
41 let g:LanguageClient_settingsPath = "~/.vim/settings.json"
42 let g:LanguageClient_waitOutputTimeout = 60
43 "let g:LanguageClient_loggingFile = expand('~/.vim/LanguageClient.log')