You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
143 lines
2.8 KiB
Lua
143 lines
2.8 KiB
Lua
return {
|
|
{
|
|
'mfussenegger/nvim-dap',
|
|
dependencies = {
|
|
'nvim-neotest/nvim-nio',
|
|
},
|
|
keys = {
|
|
{
|
|
'<leader>db',
|
|
function()
|
|
require('dap').toggle_breakpoint()
|
|
end,
|
|
desc = 'Toggle [d]ap [b]reakpoint',
|
|
},
|
|
{
|
|
'<F5>',
|
|
function()
|
|
require('dap').continue()
|
|
end,
|
|
desc = 'dap continue',
|
|
},
|
|
},
|
|
},
|
|
{
|
|
'mfussenegger/nvim-dap-python',
|
|
ft = 'python',
|
|
dependencies = {
|
|
'mfussenegger/nvim-dap',
|
|
'rcarriga/nvim-dap-ui',
|
|
},
|
|
config = function()
|
|
local path = '~/.local/share/nvim/mason/packages/debugpy/venv/bin/python'
|
|
require('dap-python').setup(path)
|
|
end,
|
|
},
|
|
{
|
|
'leoluz/nvim-dap-go',
|
|
ft = 'go',
|
|
dependencies = {
|
|
'mfussenegger/nvim-dap',
|
|
'rcarriga/nvim-dap-ui',
|
|
},
|
|
config = function()
|
|
require('dap-go').setup(opts)
|
|
end,
|
|
},
|
|
|
|
{
|
|
'rcarriga/nvim-dap-ui',
|
|
keys = {
|
|
{
|
|
'<leader>du',
|
|
function()
|
|
require('dapui').toggle()
|
|
end,
|
|
desc = 'Toggle [d]ap [u]i',
|
|
silent = true,
|
|
},
|
|
},
|
|
opts = {
|
|
controls = {
|
|
element = 'repl',
|
|
enabled = true,
|
|
icons = {
|
|
disconnect = '',
|
|
pause = '',
|
|
play = '',
|
|
run_last = '',
|
|
step_back = '',
|
|
step_into = '',
|
|
step_out = '',
|
|
step_over = '',
|
|
terminate = '',
|
|
},
|
|
},
|
|
element_mappings = {},
|
|
expand_lines = true,
|
|
floating = {
|
|
border = 'single',
|
|
mappings = {
|
|
close = { 'q', '<Esc>' },
|
|
},
|
|
},
|
|
force_buffers = true,
|
|
icons = {
|
|
collapsed = '',
|
|
current_frame = '',
|
|
expanded = '',
|
|
},
|
|
layouts = {
|
|
{
|
|
elements = {
|
|
{
|
|
id = 'scopes',
|
|
size = 0.25,
|
|
},
|
|
{
|
|
id = 'breakpoints',
|
|
size = 0.25,
|
|
},
|
|
{
|
|
id = 'stacks',
|
|
size = 0.25,
|
|
},
|
|
{
|
|
id = 'watches',
|
|
size = 0.25,
|
|
},
|
|
},
|
|
position = 'left',
|
|
size = 40,
|
|
},
|
|
{
|
|
elements = { {
|
|
id = 'repl',
|
|
size = 0.5,
|
|
}, {
|
|
id = 'console',
|
|
size = 0.5,
|
|
} },
|
|
position = 'bottom',
|
|
size = 10,
|
|
},
|
|
},
|
|
mappings = {
|
|
edit = 'e',
|
|
expand = { '<CR>', '<2-LeftMouse>' },
|
|
open = 'o',
|
|
remove = 'd',
|
|
repl = 'r',
|
|
toggle = 't',
|
|
},
|
|
render = {
|
|
indent = 1,
|
|
max_value_lines = 100,
|
|
},
|
|
},
|
|
config = function(_, opts)
|
|
require('dapui').setup(opts)
|
|
end,
|
|
},
|
|
}
|