completions, dashboard, debug, lsp, none-ls, treesitter
This commit is contained in:
parent
cc3f80c743
commit
e00ef683fa
7 changed files with 180 additions and 34 deletions
37
lua/plugins/debug.lua
Normal file
37
lua/plugins/debug.lua
Normal file
|
|
@ -0,0 +1,37 @@
|
|||
return {
|
||||
'mfussenegger/nvim-dap',
|
||||
dependencies = {
|
||||
'rcarriga/nvim-dap-ui',
|
||||
'leoluz/nvim-dap-go',
|
||||
},
|
||||
config = function()
|
||||
local dap = require('dap')
|
||||
local dapui = require("dapui")
|
||||
|
||||
require('dap-go').setup()
|
||||
require('dapui').setup()
|
||||
|
||||
vim.keymap.set('n', '<leader>dc', function() dap.continue() end)
|
||||
vim.keymap.set('n', '<F10>', function() dap.step_over() end)
|
||||
vim.keymap.set('n', '<F11>', function() dap.step_into() end)
|
||||
vim.keymap.set('n', '<F12>', function() dap.step_out() end)
|
||||
vim.keymap.set('n', '<Leader>b', function() dap.toggle_breakpoint() end)
|
||||
vim.keymap.set('n', '<Leader>B', function() dap.set_breakpoint() end)
|
||||
vim.keymap.set('n', '<Leader>lp',
|
||||
function() dap.set_breakpoint(nil, nil, vim.fn.input('Log point message: ')) end)
|
||||
vim.keymap.set('n', '<Leader>dr', function() dap.repl.open() end)
|
||||
vim.keymap.set('n', '<Leader>dl', function() dap.run_last() end)
|
||||
dap.listeners.before.attach.dapui_config = function()
|
||||
dapui.open()
|
||||
end
|
||||
dap.listeners.before.launch.dapui_config = function()
|
||||
dapui.open()
|
||||
end
|
||||
dap.listeners.before.event_terminated.dapui_config = function()
|
||||
dapui.close()
|
||||
end
|
||||
dap.listeners.before.event_exited.dapui_config = function()
|
||||
dapui.close()
|
||||
end
|
||||
end
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue