From 83b15578f12aea020a50ece800002ce9ff8e4c14 Mon Sep 17 00:00:00 2001 From: xesc Date: Mon, 27 May 2024 12:07:46 +0200 Subject: [PATCH] remove deprecated sign-set func --- lua/plugin/lspconfig.lua | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lua/plugin/lspconfig.lua b/lua/plugin/lspconfig.lua index 4aef552..008667e 100644 --- a/lua/plugin/lspconfig.lua +++ b/lua/plugin/lspconfig.lua @@ -16,11 +16,6 @@ return { -- enable completion triggered by vim.api.nvim_buf_set_option(bufnr, 'omnifunc', 'v:lua.vim.lsp.omnifunc') end - 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 }) - end local border = { { "╭", "FloatBorder" }, @@ -34,6 +29,7 @@ return { } vim.diagnostic.config({ + signs = { text = { [vim.diagnostic.severity.ERROR] = "✘ ", [vim.diagnostic.severity.WARN] = " ", [vim.diagnostic.severity.HINT] = " ", [vim.diagnostic.severity.INFO] = " " } }, float = { border = border }, virtual_text = { prefix = '●', -- Could be '●', '■', 'x', '▎', or anything else