From dfe535907a38dec64833009cf5aabe117af73f92 Mon Sep 17 00:00:00 2001 From: Phantop Date: Fri, 19 Jul 2024 18:46:33 -0400 Subject: [PATCH] nvim: more lsp bindings for definitions :) --- nvim/init.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/nvim/init.lua b/nvim/init.lua index ee06f00..b98a6e4 100755 --- a/nvim/init.lua +++ b/nvim/init.lua @@ -112,6 +112,9 @@ vim.g.mapleader = " " vim.keymap.set("n", "{", "AerialPrev", { buffer = bufnr }) vim.keymap.set("n", "}", "AerialNext", { buffer = bufnr }) vim.keymap.set('n', 'a', "AerialToggle!") +vim.keymap.set('n', 'gd', function() vim.lsp.buf.definition() end) +vim.keymap.set('n', 'gD', function() vim.lsp.buf.type_definition() end) +vim.keymap.set('n', 'd', function() vim.lsp.buf.definition() end) vim.keymap.set('n', 'f', function() vim.lsp.buf.code_action() end) vim.keymap.set('n', 'h', function() vim.lsp.buf.hover() end) vim.keymap.set('n', 'r', function() vim.lsp.buf.rename() end)