show source in diagnostic errors

This commit is contained in:
Dmitry O 2024-03-31 22:24:46 +02:00
parent 79df86ff35
commit f0ecb97348
No known key found for this signature in database
GPG Key ID: F3F70C3C74A4BDA6
1 changed files with 3 additions and 1 deletions

View File

@ -168,7 +168,9 @@ end, { desc = 'Go to previous [D]iagnostic message' })
vim.keymap.set('n', ']d', function() vim.keymap.set('n', ']d', function()
vim.diagnostic.goto_next { float = { source = true } } vim.diagnostic.goto_next { float = { source = true } }
end, { desc = 'Go to next [D]iagnostic message' }) end, { desc = 'Go to next [D]iagnostic message' })
vim.keymap.set('n', '<leader>e', vim.diagnostic.open_float, { desc = 'Show diagnostic [E]rror messages' }) vim.keymap.set('n', '<leader>e', function()
vim.diagnostic.open_float { source = true }
end, { desc = 'Show diagnostic [E]rror messages' })
vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, { desc = 'Open diagnostic [Q]uickfix list' }) vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, { desc = 'Open diagnostic [Q]uickfix list' })
-- Exit terminal mode in the builtin terminal with a shortcut that is a bit easier -- Exit terminal mode in the builtin terminal with a shortcut that is a bit easier