2026 nvim config
This commit is contained in:
19
lua/plugins/harpoon.lua
Normal file
19
lua/plugins/harpoon.lua
Normal file
@@ -0,0 +1,19 @@
|
||||
-- ~/.config/nvim/lua/plugins/harpoon.lua
|
||||
|
||||
return {
|
||||
"ThePrimeagen/harpoon",
|
||||
branch = "harpoon2", -- Use the latest Harpoon 2 branch for best support
|
||||
dependencies = { "nvim-lua/plenary.nvim" },
|
||||
config = function()
|
||||
require("harpoon"):setup({})
|
||||
-- Map <leader>h to toggle the Harpoon quick menu
|
||||
vim.keymap.set("n", "<leader>h", function()
|
||||
require("harpoon").ui:toggle_quick_menu(require("harpoon"):list())
|
||||
end, { desc = "Harpoon quick menu" })
|
||||
-- Optionally add a key to add the current file (or directory) to Harpoon
|
||||
vim.keymap.set("n", "<leader>m", function()
|
||||
require("harpoon"):list():add()
|
||||
end, { desc = "Mark file (Harpoon)" })
|
||||
end,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user