Create wrapper directly to codelldb plugin.

main
Joshua Potter 2023-11-22 10:22:02 -07:00
parent af9f2f6b10
commit 4bda4b8385
2 changed files with 8 additions and 6 deletions

View File

@ -2,14 +2,16 @@
{
home.packages = with pkgs; [
clang-tools
vscode-extensions.vadimcn.vscode-lldb
(writeShellScriptBin "codelldb" ''
#!/usr/bin/env bash
exec ${vscode-extensions.vadimcn.vscode-lldb}/share/vscode/extensions/vadimcn.vscode-lldb/adapter/codelldb "$@"
'')
];
programs.neovim = {
nvim-dap = ''
require('init.c').nvim_dap({
command = '${pkgs.vscode-extensions.vadimcn.vscode-lldb}/share/vscode/extensions/vadimcn.vscode-lldb/adapter/codelldb'
})
require('init.c').nvim_dap()
'';
nvim-lspconfig = ''

View File

@ -1,6 +1,6 @@
local M = {}
function M.nvim_dap(options)
function M.nvim_dap()
local dap = require('dap')
local key = 'codelldb'
@ -8,7 +8,7 @@ function M.nvim_dap(options)
type = 'server',
port = '${port}',
executable = {
command = options.command,
command = 'codelldb',
args = {'--port', '${port}'},
},
}