Skip to content

Commit

Permalink
Add LSP goto keymaps
Browse files Browse the repository at this point in the history
  • Loading branch information
sestrella committed Apr 3, 2024
1 parent a609fa4 commit a266b33
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions home/neovim/plugins/lspconfig/config.lua
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,10 @@ vim.api.nvim_create_autocmd("LspAttach", {
vim.keymap.set("n", keys, func, { buffer = event.buf, desc = desc })
end

local builtin = require("telescope.builtin")
map("gd", builtin.lsp_definitions, "[G]oto [D]efinition")
map("gr", builtin.lsp_references, "[G]oto [R]eferences")

map("<leader>rn", vim.lsp.buf.rename, "[R]e[n]ame")
map("<leader>ca", vim.lsp.buf.code_action, "[C]ode [A]ction")

Expand Down

0 comments on commit a266b33

Please sign in to comment.