nvim/after/plugin/dap.lua

28 lines
751 B
Lua
Raw Normal View History

2024-10-19 07:57:01 +00:00
local dap = require('dap')
local dapui = require("dapui")
vim.keymap.set("n", "<leader>dd", function() dap.continue() end)
vim.keymap.set("n", "<leader>db", function() dap.toggle_breakpoint() end)
vim.keymap.set("n", "<leader>dn", function() dap.step_over() end)
dapui.setup()
vim.keymap.set("n", "<leader>vd", function() dapui.toggle() end)
dap.listeners.before.attach.dapui_config = function()
dapui.open()
end
dap.listeners.before.launch.dapui_config = function()
dapui.open()
end
dap.listeners.before.event_terminated.dapui_config = function()
dapui.close()
end
dap.listeners.before.event_exited.dapui_config = function()
dapui.close()
end
-- python
require('dap-python').setup('~/.local/share/nvim/.virtualenvs/debugpy/bin/python')