Add virtual text and remove default icon in debugger, add GDB path for desktop
This commit is contained in:
parent
1f8b7465e6
commit
3c373aeb49
2 changed files with 53 additions and 19 deletions
|
|
@ -13,7 +13,7 @@ return {
|
|||
dependencies = {
|
||||
-- Creates a beautiful debugger UI
|
||||
'rcarriga/nvim-dap-ui',
|
||||
|
||||
'theHamsta/nvim-dap-virtual-text',
|
||||
-- Required dependency for nvim-dap-ui
|
||||
'nvim-neotest/nvim-nio',
|
||||
|
||||
|
|
@ -73,19 +73,53 @@ return {
|
|||
-- Set icons to characters that are more likely to work in every terminal.
|
||||
-- Feel free to remove or use ones that you like more! :)
|
||||
-- Don't feel like these are good choices.
|
||||
icons = { expanded = '▾', collapsed = '▸', current_frame = '*' },
|
||||
controls = {
|
||||
icons = {
|
||||
pause = '⏸',
|
||||
play = '▶',
|
||||
step_into = '⏎',
|
||||
step_over = '⏭',
|
||||
step_out = '⏮',
|
||||
step_back = 'b',
|
||||
run_last = '▶▶',
|
||||
terminate = '⏹',
|
||||
disconnect = '⏏',
|
||||
},
|
||||
-- icons = { expanded = '▾', collapsed = '▸', current_frame = '*' },
|
||||
-- controls = {
|
||||
-- icons = {
|
||||
-- pause = '⏸',
|
||||
-- play = '▶',
|
||||
-- step_into = '⏎',
|
||||
-- step_over = '⏭',
|
||||
-- step_out = '⏮',
|
||||
-- step_back = 'b',
|
||||
-- run_last = '▶▶',
|
||||
-- terminate = '⏹',
|
||||
-- disconnect = '⏏',
|
||||
-- },
|
||||
-- },
|
||||
}
|
||||
|
||||
--GDB config
|
||||
dap.adapters.cppdbg = {
|
||||
id = 'cppdbg',
|
||||
type = 'executable',
|
||||
command = 'C:Users/A/.vscode/extensions/ms-vscode.cpptools-1.23.1-win32-x64/debugAdapters/bin/OpenDebugAD7.exe',
|
||||
options = {
|
||||
detached = false,
|
||||
},
|
||||
}
|
||||
dap.configurations.cpp = {
|
||||
{
|
||||
name = 'Launch file',
|
||||
type = 'cppdbg',
|
||||
request = 'launch',
|
||||
program = function()
|
||||
return vim.fn.input('Path to executable: ', vim.fn.getcwd() .. '/', 'file')
|
||||
end,
|
||||
cwd = '${workspaceFolder}',
|
||||
stopAtEntry = true,
|
||||
},
|
||||
{
|
||||
name = 'Attach to gdbserver :1234',
|
||||
type = 'cppdbg',
|
||||
request = 'launch',
|
||||
MIMode = 'gdb',
|
||||
miDebuggerServerAddress = 'localhost:1234',
|
||||
miDebuggerPath = '/usr/bin/gdb',
|
||||
cwd = '${workspaceFolder}',
|
||||
program = function()
|
||||
return vim.fn.input('Path to executable: ', vim.fn.getcwd() .. '/', 'file')
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue