fixed dap config

This commit is contained in:
Oliver Hartmann 2024-04-26 09:15:57 +00:00
parent 4dc7351d8b
commit 57eb3586d9

View File

@ -3,7 +3,12 @@ return {
dependencies = {
'mfussenegger/nvim-dap-python',
'theHamsta/nvim-dap-virtual-text',
'rcarriga/nvim-dap-ui',
{
'rcarriga/nvim-dap-ui',
dependencies = {
'nvim-neotest/nvim-nio'
}
},
'rcarriga/cmp-dap',
},
keys = {
@ -95,7 +100,7 @@ return {
config.pythonPath = pythonVenv.getPythonEnv()
config.cwd = vim.fn.getcwd()
end
require ('fzf-lua').dap_configurations()
require('fzf-lua').dap_configurations()
end
local masonpath = vim.fn.stdpath('data') .. '/mason'
@ -103,7 +108,7 @@ return {
-- PYTHON
dap.adapters.python = {
type = 'executable',
command = masonpath .. '/packages/debugpy/venv/' .. pythonVenv.getVenvSuffix(),
command = 'python',
args = { '-m', 'debugpy.adapter' },
options = {
detached = true,
@ -150,7 +155,7 @@ return {
type = 'server',
port = '${port}',
executable = {
command = require'mason-core.path'.bin_prefix'codelldb';
command = require 'mason-core.path'.bin_prefix 'codelldb',
args = { '--port', '${port}' },
-- On windows you may have to uncomment this:
@ -182,7 +187,7 @@ return {
type = 'codelldb',
request = 'launch',
program = function()
return vim.fn.input({'Path to executable: ', vim.fn.getcwd() .. '/build_nvim/', 'file'})
return vim.fn.input({ 'Path to executable: ', vim.fn.getcwd() .. '/build_nvim/', 'file' })
end,
cwd = '${workspaceFolder}',
stopOnEntry = false,
@ -192,7 +197,7 @@ return {
type = 'lldb',
request = 'launch',
program = function()
return vim.fn.input({'Path to executable: ', vim.fn.getcwd() .. '/build_nvim', 'file'})
return vim.fn.input({ 'Path to executable: ', vim.fn.getcwd() .. '/build_nvim', 'file' })
end,
cwd = '${workspaceFolder}',
stopOnEntry = false,