fix: Fixes moving lines up and down in nvim keymaps

This commit is contained in:
2024-11-10 11:25:22 -05:00
parent f7484147f7
commit 051a418d0b
3 changed files with 31 additions and 8 deletions

View File

@@ -41,13 +41,23 @@ return {
)
-- Toggle previous and next buffers.
vim.keymap.set("n", "<C-S-P>",
vim.keymap.set("n", "<C-[>",
function() harpoon:list():prev() end,
{ desc = "[P]revious harpoon buffer." }
)
vim.keymap.set("n", "<C-S-N>",
vim.keymap.set("n", "<C-]>",
function() harpoon:list():next() end,
{ desc = "[N]ext harpoon buffer." }
)
-- Extensions
harpoon:extend({
UI_CREATE = function(cx)
vim.keymap.set("n", "<C-v>",
function() harpoon.ui:select_menu_item({ vsplit = true }) end,
{ buffer = cx.buffer, desc = "Open in [V]split" }
)
end
})
end
}

View File

@@ -70,7 +70,7 @@ return {
local wk = require('which-key')
wk.add({
{ "K", vim.lsp.buf.hover, desc = "LSP hover info" },
{ "<C-k>", vim.lsp.buf.hover, desc = "LSP hover info" },
{ "gd", vim.lsp.buf.definition, desc = "[G]oto [D]efinition" },
{ "gD", vim.lsp.buf.declaration, desc = "[G]oto [D]eclaration" },
{ "gi", vim.lsp.buf.implementation, desc = "[G]oto [I]mplementation" },