diff --git a/lua/kickstart/plugins/debug.lua b/lua/kickstart/plugins/debug.lua index 8e332bf2..1840137e 100644 --- a/lua/kickstart/plugins/debug.lua +++ b/lua/kickstart/plugins/debug.lua @@ -1,15 +1,5 @@ --- debug.lua --- --- Shows how to use the DAP plugin to debug your code. --- --- Primarily focused on configuring the debugger for Go, but can --- be extended to other languages as well. That's why it's called --- kickstart.nvim and not kitchen-sink.nvim ;) - return { - -- NOTE: Yes, you can install new plugins here! 'mfussenegger/nvim-dap', - -- NOTE: And you can specify dependencies as well dependencies = { -- Creates a beautiful debugger UI 'rcarriga/nvim-dap-ui', @@ -22,33 +12,33 @@ return { 'jay-babu/mason-nvim-dap.nvim', -- Add your own debuggers here - 'leoluz/nvim-dap-go', + 'mfussenegger/nvim-dap-python', }, keys = { -- Basic debugging keymaps, feel free to change to your liking! { - '', + '', function() require('dap').continue() end, desc = 'Debug: Start/Continue', }, { - '', + '', function() require('dap').step_into() end, desc = 'Debug: Step Into', }, { - '', + '', function() require('dap').step_over() end, desc = 'Debug: Step Over', }, { - '', + '', function() require('dap').step_out() end, @@ -70,7 +60,7 @@ return { }, -- Toggle to see last session result. Without this, you can't see session output in case of unhandled exception. { - '', + '', function() require('dapui').toggle() end, @@ -82,22 +72,16 @@ return { local dapui = require 'dapui' require('mason-nvim-dap').setup { - -- Makes a best effort to setup the various debuggers with - -- reasonable debug configurations automatic_installation = true, - - -- You can provide additional configuration to the handlers, - -- see mason-nvim-dap README for more information handlers = {}, - - -- You'll need to check that you have the required things installed - -- online, please don't ask me how to install them :) ensure_installed = { - -- Update this to ensure that you have the debuggers for the langs you want - 'delve', + 'python', }, } + require('dap-python').setup 'uv' + require('dap-python').test_runner = 'pytest' + -- Dap UI setup -- For more information, see |:help nvim-dap-ui| dapui.setup { @@ -135,14 +119,5 @@ return { dap.listeners.after.event_initialized['dapui_config'] = dapui.open dap.listeners.before.event_terminated['dapui_config'] = dapui.close dap.listeners.before.event_exited['dapui_config'] = dapui.close - - -- Install golang specific config - require('dap-go').setup { - delve = { - -- On Windows delve must be run attached or it crashes. - -- See https://github.com/leoluz/nvim-dap-go/blob/main/README.md#configuring - detached = vim.fn.has 'win32' == 0, - }, - } end, } diff --git a/lua/kickstart/plugins/mini.lua b/lua/kickstart/plugins/mini.lua index 5403e5b0..12f12240 100644 --- a/lua/kickstart/plugins/mini.lua +++ b/lua/kickstart/plugins/mini.lua @@ -16,6 +16,8 @@ return { -- Collection of various small independent plugins/modules -- - sr)' - [S]urround [R]eplace [)] ['] require('mini.surround').setup() + require('mini.comment').setup() + -- Simple and easy statusline. -- You could remove this setup call if you don't like it, -- and try some other statusline plugin diff --git a/lua/kickstart/plugins/todo-comments.lua b/lua/kickstart/plugins/todo-comments.lua index 117112bf..ae2b0d66 100644 --- a/lua/kickstart/plugins/todo-comments.lua +++ b/lua/kickstart/plugins/todo-comments.lua @@ -1,3 +1,3 @@ -return { 'folke/todo-comments.nvim', event = 'VimEnter', dependencies = { 'nvim-lua/plenary.nvim' }, opts = { signs = false } } +return { 'folke/todo-comments.nvim', event = 'VimEnter', dependencies = { 'nvim-lua/plenary.nvim' }, opts = {} } -- vim: ts=2 sts=2 sw=2 et diff --git a/lua/lazy-plugins.lua b/lua/lazy-plugins.lua index bcfd02ad..06efd09e 100644 --- a/lua/lazy-plugins.lua +++ b/lua/lazy-plugins.lua @@ -26,6 +26,8 @@ require('lazy').setup({ require 'kickstart.plugins.indent_line', require 'kickstart.plugins.lint', + + require 'kickstart.plugins.debug', }, { ui = { -- If you are using a Nerd Font: set icons to an empty table which will use the