Files
swaits f8cce8da37 feat: add 10 new language adapters
Adds Dart (with optional Flutter auto-detection), Bash (bash-debug-adapter with mason bashdb_dir probing), R (vscDebugger package preflight), Elixir (mix_task), Haskell, OCaml (ocamlearlybird), Zig/Nim/Crystal (via codelldb filetype extension), and F# (via netcoredbg filetype extension). Expands built-in adapter coverage from 12 to 22 languages.
2026-04-12 20:42:49 -06:00

40 lines
1011 B
Lua

local loader = require("turbo-debug.adapters.init")
local M = {}
function M.register(dap)
local exe = loader.find_executable({ "bash-debug-adapter" })
if not exe then return end
local bashdb_dir = vim.fn.stdpath("data") .. "/mason/packages/bash-debug-adapter/extension/bashdb_dir"
if vim.fn.isdirectory(bashdb_dir) == 0 then bashdb_dir = nil end
loader.register(dap, "bashdb", {
type = "executable",
command = exe,
name = "bashdb",
}, {
{
type = "bashdb",
request = "launch",
name = "Launch file",
showDebugOutput = true,
pathBashdb = bashdb_dir and (bashdb_dir .. "/bashdb") or "bashdb",
pathBashdbLib = bashdb_dir,
trace = true,
file = "${file}",
program = "${file}",
cwd = "${workspaceFolder}",
pathCat = "cat",
pathBash = "/bin/bash",
pathMkfifo = "mkfifo",
pathPkill = "pkill",
args = {},
env = {},
terminalKind = "integrated",
},
}, { "sh", "bash" })
end
return M