add trouble

side note? why was I using feat and chore and etc?
This commit is contained in:
Zoty 2026-04-07 11:46:51 -03:00
parent af16bba334
commit d65c4083ba
Signed by: Zoty
SSH key fingerprint: SHA256:WsGEGivgl37t3Mth6uugXMOgMCTR7QolIepNbC+j/tA
9 changed files with 80 additions and 46 deletions

23
lua/plugins/trouble.lua Normal file
View file

@ -0,0 +1,23 @@
return {
'folke/trouble.nvim',
dependencies = { 'nvim-tree/nvim-web-devicons' },
opts = {
modes = {
diagnostics = {
mode = "diagnostics",
preview = {
type = "diagnostics",
relative = "win",
position = "right",
size = 0.4,
},
},
},
},
keys = {
{ '<leader>xx', '<cmd>Trouble diagnostics toggle<cr>', desc = 'Diagnostics (workspace)' },
{ '<leader>xd', '<cmd>Trouble diagnostics toggle filter.buf=0<cr>', desc = 'Diagnostics (buffer)' },
{ ']t', function() require('trouble').next({ skip_groups = true, jump = true }) end, desc = 'Next trouble item' },
{ '[t', function() require('trouble').prev({ skip_groups = true, jump = true }) end, desc = 'Prev trouble item' },
}
}