|
|
@ -20,6 +20,12 @@ local default_config = {
|
|
|
|
vim.keymap.set("n", sequence, cmd, { buffer = bufnr, desc = desc })
|
|
|
|
vim.keymap.set("n", sequence, cmd, { buffer = bufnr, desc = desc })
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
map("K", vim.lsp.buf.hover, "Hover")
|
|
|
|
|
|
|
|
map("]d", vim.diagnostic.goto_next, "Next diagnostic")
|
|
|
|
|
|
|
|
map("[d", vim.diagnostic.goto_prev, "Previous diagnostic")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
map("gs", vim.lsp.buf.signature_help, "LSP Signature Help")
|
|
|
|
|
|
|
|
map("gD", vim.lsp.buf.declaration, "LSP Declarations")
|
|
|
|
map("gd", function()
|
|
|
|
map("gd", function()
|
|
|
|
require("telescope.builtin").lsp_definitions()
|
|
|
|
require("telescope.builtin").lsp_definitions()
|
|
|
|
end, "LSP Definitions")
|
|
|
|
end, "LSP Definitions")
|
|
|
@ -29,9 +35,11 @@ local default_config = {
|
|
|
|
map("gI", function()
|
|
|
|
map("gI", function()
|
|
|
|
require("telescope.builtin").lsp_implementations()
|
|
|
|
require("telescope.builtin").lsp_implementations()
|
|
|
|
end, "LSP Implementations")
|
|
|
|
end, "LSP Implementations")
|
|
|
|
map("K", vim.lsp.buf.hover, "Hover")
|
|
|
|
map("gl", function()
|
|
|
|
map("]d", vim.diagnostic.goto_next, "Next diagnostic")
|
|
|
|
vim.diagnostic.open_float(0, {
|
|
|
|
map("[d", vim.diagnostic.goto_prev, "Previous diagnostic")
|
|
|
|
scope = "line",
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
end)
|
|
|
|
|
|
|
|
|
|
|
|
map("<leader>la", vim.lsp.buf.code_action, "Code Action")
|
|
|
|
map("<leader>la", vim.lsp.buf.code_action, "Code Action")
|
|
|
|
map("<leader>lr", vim.lsp.buf.rename, "Rename")
|
|
|
|
map("<leader>lr", vim.lsp.buf.rename, "Rename")
|
|
|
|