From e25dc486a3daa752144e3fe673061264798d5c40 Mon Sep 17 00:00:00 2001 From: 409 <409dev@protonmail.com> Date: Wed, 19 Feb 2025 03:09:26 +0100 Subject: [PATCH] feat(keybinds): `gi` jumps to first instead of opening quickfix --- lua/409/plugins/lsp.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lua/409/plugins/lsp.lua b/lua/409/plugins/lsp.lua index 7ac90c6..0d8290d 100644 --- a/lua/409/plugins/lsp.lua +++ b/lua/409/plugins/lsp.lua @@ -42,7 +42,11 @@ return { }) end, { buffer = bufnr, remap = false, nowait = true }) vim.keymap.set("n", "gi", function() - vim.lsp.buf.implementation() + vim.lsp.buf.implementation({ + on_list = function(list) + vim.lsp.util.jump_to_location(list.items[1].user_data, "utf-8", true) + end, + }) end, lsp_opts) vim.keymap.set("n", "K", function() vim.lsp.buf.hover()