Enable csharp debugging

This commit is contained in:
Jorge Benavente 2024-05-02 22:37:06 +02:00
parent 23773900d9
commit 6f7b123c36
2 changed files with 14 additions and 4 deletions

View File

@ -91,7 +91,7 @@ vim.g.mapleader = ' '
vim.g.maplocalleader = ' ' vim.g.maplocalleader = ' '
-- Set to true if you have a Nerd Font installed -- Set to true if you have a Nerd Font installed
vim.g.have_nerd_font = false vim.g.have_nerd_font = true
-- [[ Setting options ]] -- [[ Setting options ]]
-- See `:help vim.opt` -- See `:help vim.opt`
@ -100,6 +100,7 @@ vim.g.have_nerd_font = false
-- Make line numbers default -- Make line numbers default
vim.opt.number = true vim.opt.number = true
vim.opt.relativenumber = true
-- You can also add relative line numbers, to help with jumping. -- You can also add relative line numbers, to help with jumping.
-- Experiment for yourself to see if you like it! -- Experiment for yourself to see if you like it!
-- vim.opt.relativenumber = true -- vim.opt.relativenumber = true
@ -548,7 +549,10 @@ require('lazy').setup({
-- https://github.com/pmizio/typescript-tools.nvim -- https://github.com/pmizio/typescript-tools.nvim
-- --
-- But for many setups, the LSP (`tsserver`) will work just fine -- But for many setups, the LSP (`tsserver`) will work just fine
-- tsserver = {}, tsserver = {
'prettierd',
'eslint',
},
-- --
lua_ls = { lua_ls = {
@ -580,6 +584,8 @@ require('lazy').setup({
local ensure_installed = vim.tbl_keys(servers or {}) local ensure_installed = vim.tbl_keys(servers or {})
vim.list_extend(ensure_installed, { vim.list_extend(ensure_installed, {
'stylua', -- Used to format Lua code 'stylua', -- Used to format Lua code
'omnisharp',
'netcoredbg',
}) })
require('mason-tool-installer').setup { ensure_installed = ensure_installed } require('mason-tool-installer').setup { ensure_installed = ensure_installed }
@ -630,7 +636,7 @@ require('lazy').setup({
-- --
-- You can use a sub-list to tell conform to run *until* a formatter -- You can use a sub-list to tell conform to run *until* a formatter
-- is found. -- is found.
-- javascript = { { "prettierd", "prettier" } }, javascript = { { 'prettierd', 'prettier' } },
}, },
}, },
}, },
@ -838,7 +844,7 @@ require('lazy').setup({
-- Here are some example plugins that I've included in the Kickstart repository. -- Here are some example plugins that I've included in the Kickstart repository.
-- Uncomment any of the lines below to enable them (you will need to restart nvim). -- Uncomment any of the lines below to enable them (you will need to restart nvim).
-- --
-- require 'kickstart.plugins.debug', require 'kickstart.plugins.debug',
-- require 'kickstart.plugins.indent_line', -- require 'kickstart.plugins.indent_line',
-- require 'kickstart.plugins.lint', -- require 'kickstart.plugins.lint',

View File

@ -23,6 +23,7 @@ return {
-- Add your own debuggers here -- Add your own debuggers here
'leoluz/nvim-dap-go', 'leoluz/nvim-dap-go',
'nicholasmata/nvim-dap-cs',
}, },
config = function() config = function()
local dap = require 'dap' local dap = require 'dap'
@ -32,6 +33,7 @@ return {
-- Makes a best effort to setup the various debuggers with -- Makes a best effort to setup the various debuggers with
-- reasonable debug configurations -- reasonable debug configurations
automatic_setup = true, automatic_setup = true,
automatic_installation = true,
-- You can provide additional configuration to the handlers, -- You can provide additional configuration to the handlers,
-- see mason-nvim-dap README for more information -- see mason-nvim-dap README for more information
@ -42,6 +44,7 @@ return {
ensure_installed = { ensure_installed = {
-- Update this to ensure that you have the debuggers for the langs you want -- Update this to ensure that you have the debuggers for the langs you want
'delve', 'delve',
'netcoredbg',
}, },
} }
@ -86,5 +89,6 @@ return {
-- Install golang specific config -- Install golang specific config
require('dap-go').setup() require('dap-go').setup()
require('dap-cs').setup()
end, end,
} }