summaryrefslogtreecommitdiff
path: root/fnl/plugins/lsp
diff options
context:
space:
mode:
authorGustaf Rydholm <gustaf.rydholm@gmail.com>2024-12-26 00:05:03 +0100
committerGustaf Rydholm <gustaf.rydholm@gmail.com>2024-12-26 00:05:03 +0100
commit8079b4c5a5b00a24f408c72b839ad328c01f9258 (patch)
treedf5304547a16f4a3f1f057871860c540e5717c5d /fnl/plugins/lsp
parentf8e0a6bcdce27e7dc964f0d12612b254f0b29fc4 (diff)
Fix blink.cmp opts
Diffstat (limited to 'fnl/plugins/lsp')
-rw-r--r--fnl/plugins/lsp/diagnostics.fnl4
-rw-r--r--fnl/plugins/lsp/mason-lspconfig.fnl6
2 files changed, 7 insertions, 3 deletions
diff --git a/fnl/plugins/lsp/diagnostics.fnl b/fnl/plugins/lsp/diagnostics.fnl
index 3c24b5c..b4aefa6 100644
--- a/fnl/plugins/lsp/diagnostics.fnl
+++ b/fnl/plugins/lsp/diagnostics.fnl
@@ -20,8 +20,6 @@
:prefix ""}})
(λ setup []
- (vim.diagnostic.config config)
- (set vim.lsp.handlers.textDocument/hover false)
- (set vim.lsp.handlers.textDocument/signatureHelp false))
+ (vim.diagnostic.config config))
{: setup}
diff --git a/fnl/plugins/lsp/mason-lspconfig.fnl b/fnl/plugins/lsp/mason-lspconfig.fnl
index fbf3d1d..429e948 100644
--- a/fnl/plugins/lsp/mason-lspconfig.fnl
+++ b/fnl/plugins/lsp/mason-lspconfig.fnl
@@ -1,6 +1,11 @@
;; A bridge plugin between mason and lspconfig, handles installation of lsp and
;; setup hooks for client configurations.
+(local textDocument-handlers
+ {:textDocument/hover (vim.lsp.with vim.lsp.handlers.hover {:border :single})
+ :textDocument/signatureHelp (vim.lsp.with vim.lsp.handlers.signature_help
+ {:border :single})})
+
(λ capabilities []
(let [blink-cmp (require :blink.cmp)]
(blink-cmp.get_lsp_capabilities)))
@@ -11,6 +16,7 @@
(let [lspconfig (. lspconfigs server)
server-config (or (. servers server) {})]
(tset server-config :capabilities (capabilities))
+ (tset server-config :handlers textDocument-handlers)
(lspconfig.setup server-config))))
(λ setup []