This commit is contained in:
Oliver Hartmann
2023-04-27 19:08:06 +02:00
3 changed files with 15 additions and 16 deletions

13
lua/plugins/lsp_lines.lua Normal file
View File

@ -0,0 +1,13 @@
return {
'https://git.sr.ht/~whynothugo/lsp_lines.nvim',
config = true,
keys = {
{
'<space>l',
function()
require('lsp_lines').toggle()
end,
desc = 'Toggle lsp_lines',
}
},
}

View File

@ -117,7 +117,6 @@ return {
vim.keymap.set('n', '<A-o>', '<cmd>ClangdSwitchSourceHeader<CR>',
{ noremap = true, silent = false, desc = 'Switch Source/Header', buffer = bufnr })
vim.cmd([[autocmd CursorHold <buffer> lua OpenDiagFloat()]])
-- Set some keybinds conditional on server capabilities
if client.server_capabilities.documentFormattingProvider then
@ -311,21 +310,7 @@ return {
})
-- vim.diagnostic.config({ virtual_text = false })
vim.diagnostic.config({
virtual_text = false,
signs = true,
float = {
border = 'single',
format = function(diagnostic)
return string.format(
'%s (%s) [%s]',
diagnostic.message,
diagnostic.source,
diagnostic.code or diagnostic.user_data.lsp.code
)
end,
},
})
vim.diagnostic.config({ virtual_text = false })
end,
event = 'VeryLazy'
}