feat: move all debug keys under <leader>d prefix with which-key support

This commit is contained in:
swaits committed 2026-04-11 19:16:36 -06:00
1 parent 94eef8eaca
commit bc015cd8dc
9 files changed
+119 -72

No files matched your search

+5 -5
View File
@@ -27,16 +27,16 @@ function M.setup()
vim.fn.sign_define("DapLogPoint", { text = "📝", texthl = "DapLogPoint" })
-- global mappings (work outside debug mode)
local keys = config.opts.keys
local gk = config.opts.global_keys
local pb = require("persistent-breakpoints.api")
local bindings = {
{ keys.breakpoint, pb.toggle_breakpoint, "toggle breakpoint" },
{ keys.cond_breakpoint, pb.set_conditional_breakpoint, "conditional breakpoint" },
{ keys.clear_breakpoints, pb.clear_all_breakpoints, "clear all breakpoints" },
{ gk.breakpoint, pb.toggle_breakpoint, "Toggle breakpoint" },
{ gk.cond_breakpoint, pb.set_conditional_breakpoint, "Conditional breakpoint" },
{ gk.clear_breakpoints, pb.clear_all_breakpoints, "Clear all breakpoints" },
}
for _, b in ipairs(bindings) do
if b[1] then
vim.keymap.set("n", b[1], b[2], { silent = true, desc = "tiny-debugger: " .. b[3] })
vim.keymap.set("n", b[1], b[2], { silent = true, desc = b[3] })
end
end
end