diff --git a/plugins/dap.lua b/plugins/dap.lua index 9055976..21f8712 100644 --- a/plugins/dap.lua +++ b/plugins/dap.lua @@ -67,10 +67,6 @@ return function() vim.notify("Failed to load .vscode/launch.json", vim.log.levels.DEBUG) end - vim.api.nvim_create_user_command("Debug", function() - dap.continue() - end, { desc = "Start debugger" }) - vim.g.dap_virtual_text = true local dapui = require "dapui" @@ -109,4 +105,29 @@ return function() dap.listeners.before.event_exited["dapui_config"] = function() dapui.close() end + + local nnoremaps = require("bombadil.lib.keymap").nnoremaps + local prefix = "d" + nnoremaps { + [prefix .. "bt"] = { + dap.toggle_breakpoint, + { desc = "[dap] Toggle breakpoint" }, + }, + [prefix .. "c"] = { + dap.continue, + { desc = "[dap] Continue" }, + }, + [prefix .. "e"] = { + dapui.eval, + { desc = "[dap] Evaluate expression" }, + }, + [prefix .. "so"] = { + dap.step_over, + { desc = "[dap] Step over" }, + }, + [prefix .. "si"] = { + dap.step_into, + { desc = "[dap] Step into" }, + }, + } end diff --git a/plugins/iron.lua b/plugins/iron.lua index 40d4976..c974408 100644 --- a/plugins/iron.lua +++ b/plugins/iron.lua @@ -9,7 +9,7 @@ return function() command = { "ts-node" }, }, }, - repl_open_cmd = view.split.vertical "40%", + repl_open_cmd = view.split "30%", }, } end diff --git a/plugins/lsp.lua b/plugins/lsp.lua index 17c2990..a8740ff 100644 --- a/plugins/lsp.lua +++ b/plugins/lsp.lua @@ -84,10 +84,6 @@ return function() end, { buffer = bufnr, desc = "Format" }, }, - ["d"] = { - vim.diagnostic.setloclist, - { buffer = bufnr, desc = "Diagnostics" }, - }, ["l"] = { vim.diagnostic.open_float, { buffer = bufnr, desc = "Line diagnostics" },