From 73ec350044e49ddbad203f4959357b4a7b17c15b Mon Sep 17 00:00:00 2001 From: sommerfeld Date: Fri, 17 Apr 2026 10:52:55 +0100 Subject: refactor(nvim): remove LSP mappings now default in 0.12 Remove gra (code_action) and cl (codelens.run) mappings. Neovim 0.12 provides these as gra and grx defaults respectively. Also remove unused nvmap helper function. --- home/.config/nvim/after/plugin/autocmds.lua | 5 ----- 1 file changed, 5 deletions(-) (limited to 'home/.config/nvim/after/plugin/autocmds.lua') diff --git a/home/.config/nvim/after/plugin/autocmds.lua b/home/.config/nvim/after/plugin/autocmds.lua index f439bec..9bbbdad 100644 --- a/home/.config/nvim/after/plugin/autocmds.lua +++ b/home/.config/nvim/after/plugin/autocmds.lua @@ -133,12 +133,8 @@ autocmd("LspAttach", { local function nmap(l, r, desc) map("n", l, r, desc) end - local function nvmap(l, r, desc) - map({ "n", "v" }, l, r, desc) - end nmap("", vim.lsp.buf.definition, "Goto definition") nmap("gD", vim.lsp.buf.declaration, "[G]oto [D]eclaration") - nvmap("gra", vim.lsp.buf.code_action, "[R]un code [A]ction") -- The following two autocommands are used to highlight references of the -- word under your cursor when your cursor rests there for a little while. @@ -194,7 +190,6 @@ autocmd("LspAttach", { callback = vim.lsp.codelens.refresh, } ) - nmap("cl", vim.lsp.codelens.run, "Run [C]ode [L]ens") end -- The following code creates a keymap to toggle inlay hints in your -- cgit v1.2.3-70-g09d2