From e00d798cfea90b1ad4db4571f55967b034099227 Mon Sep 17 00:00:00 2001 From: Martin Pander Date: Fri, 25 Jul 2025 11:14:39 +0200 Subject: [PATCH] Add lldb debug config --- nvim/plugins.lua | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/nvim/plugins.lua b/nvim/plugins.lua index 1dd40a9..27b7d4f 100644 --- a/nvim/plugins.lua +++ b/nvim/plugins.lua @@ -360,6 +360,29 @@ dap.listeners.before.event_exited.dapui_config = function() dapui.close() end +dap.adapters.codelldb = { + type = 'server', + port = "${port}", + executable = { + command = "codelldb", + args = {"--port", "${port}"}, + } +} + +dap.configurations.zig = { + { + name = "Launch Zig Program", + type = "codelldb", + request = "launch", + program = function() + -- Prompts for the executable path when you start debugging + return vim.fn.input('Path to executable: ', vim.fn.getcwd() .. '/zig-out/bin/', 'file') + end, + cwd = "${workspaceFolder}", + stopOnEntry = false, + }, +} + if vim.fn.has("mac") then workspaces = { {