Skip to content

Prepare for upcoming deprecation of configuring diagnostic-signs using sign_define()#1232

Merged
feoh merged 1 commit intonvim-lua:masterfrom
glmlm:diag
Nov 20, 2024
Merged

Prepare for upcoming deprecation of configuring diagnostic-signs using sign_define()#1232
feoh merged 1 commit intonvim-lua:masterfrom
glmlm:diag

Conversation

@glmlm
Copy link
Copy Markdown
Contributor

@glmlm glmlm commented Nov 14, 2024

Since Neovim 0.10, it seems that configuring diagnostic-signs using sign_define() has been deprecated.
There is another way to set them as follows:

if vim.g.have_nerd_font then
  vim.diagnostic.config {
    signs = {
      text = {
        [vim.diagnostic.severity.ERROR] = '',
        [vim.diagnostic.severity.WARN] = '',
        [vim.diagnostic.severity.INFO] = '',
        [vim.diagnostic.severity.HINT] = '',
      },
    },
  }
end

In the committed one, I simply focused on fewer lines and readability(after all, this section is commented out).

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants