fix: new nvim problems

nixos
Moritz Böhme 2024-05-13 10:33:17 +02:00
parent f1b86275da
commit f417d8b819
Signed by: moritz
GPG Key ID: 970C6E89EB0547A9
1 changed files with 2 additions and 7 deletions

View File

@ -23,12 +23,7 @@ local lspconfig = require("lspconfig")
local on_attach_def = function(client, bufnr) local on_attach_def = function(client, bufnr)
require("which-key").register({ require("which-key").register({
K = { K = {
function() vim.lsp.buf.hover,
local winid = require("ufo").peekFoldedLinesUnderCursor()
if not winid then
vim.lsp.buf.hover()
end
end,
"Hover", "Hover",
}, },
["<leader>"] = { ["<leader>"] = {
@ -102,7 +97,7 @@ local on_attach_def = function(client, bufnr)
} }
local timeout = vim.tbl_contains(slow_lsp_servers, client.name, {}) and 500 or 0 local timeout = vim.tbl_contains(slow_lsp_servers, client.name, {}) and 500 or 0
vim.defer_fn(function() vim.defer_fn(function()
vim.lsp.inlay_hint.enable(bufnr, true) vim.lsp.inlay_hint.enable(true, { bufnr })
end, timeout) end, timeout)
end end
end end