feat: use symbols for LSP events instead of letters

This commit is contained in:
Oliver Ladner 2024-07-30 13:47:43 +02:00
commit e2d9536c18

View file

@ -72,6 +72,22 @@ return {
{ "williamboman/mason-lspconfig.nvim", tag = "stable" },
},
config = function()
local signs = { Error = "󰅚 ", Warn = "󰀪 ", Hint = "󰌶 ", Info = "" }
for type, icon in pairs(signs) do
local hl = "DiagnosticSign" .. type
vim.fn.sign_define(hl, { text = icon, texthl = hl, numhl = hl })
end
vim.diagnostic.config({
update_in_insert = true,
signs = true,
virtual_text = {
prefix = "", -- Could be '●', '▎', 'x'
source = "if_many",
},
float = {
source = "if_many",
},
})
-- This is where all the LSP shenanigans will live
local lsp_zero = require("lsp-zero")
lsp_zero.extend_lspconfig()