diff --git a/.config/nvim/lua/dln/lsp-config.lua b/.config/nvim/lua/dln/lsp-config.lua index e2af56a..e17d107 100644 --- a/.config/nvim/lua/dln/lsp-config.lua +++ b/.config/nvim/lua/dln/lsp-config.lua @@ -10,35 +10,11 @@ vim.lsp.diagnostic.on_publish_diagnostics, virtual_text = {prefix = "โ€นโฎโฐ " } } ) -vim.fn.sign_define( -"LspDiagnosticsSignError", -{ - text = "๐Ÿ”ฅ", - texthl = "LspDiagnosticsSignError" -} -) - -vim.fn.sign_define( -"LspDiagnosticsSignWarning", -{ - text = "โš ", - texthl = "LspDiagnosticsSignWarning" -} -) -vim.fn.sign_define( -"LspDiagnosticsSignInformation", -{ - text = "๐Ÿ’ก", - texthl = "LspDiagnosticsSignInformation", -} -) -vim.fn.sign_define( -"LspDiagnosticsSignHint", -{ - text = "๐Ÿ’ก", - texthl = "LspDiagnosticsSignHint", -} -) +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 local on_attach = function() require("folding").on_attach()