]> Sergey Matveev's repositories - dotfiles.git/blobdiff - vim/.vim/plugin/lsp.vim
Signature window hides at least a line above
[dotfiles.git] / vim / .vim / plugin / lsp.vim
index ad6d0a51b508aece1db2fe11e8b7399ac4b75bed..946c5a89175f5e635c8952fc0a79b65f604d8f21 100644 (file)
@@ -3,7 +3,9 @@ vim9script
 # go get golang.org/x/tools/gopls@latest
 # pip install 'python-language-server[all]'
 
-var lspServers = [
+var lspServers: list<dict<any>>
+
+for d in [
     {
         filetype: ["c", "cpp"],
         path: "clangd",
@@ -24,14 +26,20 @@ var lspServers = [
                 mccabe: {enabled: false},
             },
         }},
-    }
+    },
 ]
+    if executable(d["path"])
+        add(lspServers, d)
+    endif
+endfor
+
 var lspOpts = {
     ignoreMissingServer: true,
     autoComplete: false,
     autoHighlight: true,
     autoPopulateDiags: true,
     showInlayHints: true,
+    showSignature: false,
 }
 
 autocmd VimEnter * call LspAddServer(lspServers)