nvim-dap-ui
This commit is contained in:
parent
09e6e6fa67
commit
556f8f0e16
3 changed files with 17 additions and 1 deletions
3
.gitmodules
vendored
3
.gitmodules
vendored
|
|
@ -79,3 +79,6 @@
|
|||
[submodule "pack/general/start/nvim-dap-go"]
|
||||
path = pack/general/start/nvim-dap-go
|
||||
url = https://github.com/leoluz/nvim-dap-go
|
||||
[submodule "pack/general/start/nvim-dap-ui"]
|
||||
path = pack/general/start/nvim-dap-ui
|
||||
url = https://github.com/rcarriga/nvim-dap-ui
|
||||
|
|
|
|||
14
init.lua
14
init.lua
|
|
@ -269,8 +269,9 @@ map('n', '<Leader>/', ':Telescope current_buffer_fuzzy_find<CR>')
|
|||
map('n', '<Leader>g', ':Telescope live_grep<CR>')
|
||||
map('n', '<Leader>cg', ':Telescope grep_string<CR>')
|
||||
---- nvim-dap
|
||||
-- nvim-dap-go
|
||||
local dap = require('dap')
|
||||
vim.fn.sign_define('DapBreakpoint',{ text ='🟥', texthl ='', linehl ='', numhl =''})
|
||||
vim.fn.sign_define('DapStopped',{ text ='▶️', texthl ='', linehl ='', numhl =''})
|
||||
-- Set keymaps to control the debugger
|
||||
vim.keymap.set('n', '<leader>dc', require 'dap'.continue)
|
||||
vim.keymap.set('n', '<leader>do', require 'dap'.step_over)
|
||||
|
|
@ -280,4 +281,15 @@ vim.keymap.set('n', '<leader>db', require 'dap'.toggle_breakpoint)
|
|||
vim.keymap.set('n', '<leader>dB', function()
|
||||
require 'dap'.set_breakpoint(vim.fn.input('Breakpoint condition: '))
|
||||
end)
|
||||
local dapui = require('dapui')
|
||||
dap.listeners.after.event_initialized["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
|
||||
-- nvim-dap-go
|
||||
require('dap-go').setup()
|
||||
|
|
|
|||
1
pack/general/start/nvim-dap-ui
Submodule
1
pack/general/start/nvim-dap-ui
Submodule
|
|
@ -0,0 +1 @@
|
|||
Subproject commit bdb94e3853d11b5ce98ec182e5a3719d5c0ef6fd
|
||||
Loading…
Add table
Reference in a new issue