2 files changed,
12 insertions(+),
50 deletions(-)
Author:
Oleksandr Smirnov
olexsmir@gmail.com
Committed at:
2025-02-19 15:21:44 +0200
Parent:
e785148
jump to
| D | lua/core/diagnostic.lua |
| M | lua/core/options.lua |
D
@@ -1,48 +0,0 @@
-local diagnostic = {} - -diagnostic.border = { - { "", "FloatBorder" }, - { "", "FloatBorder" }, - { "", "FloatBorder" }, - { "", "FloatBorder" }, - { "", "FloatBorder" }, - { "", "FloatBorder" }, - { "", "FloatBorder" }, - { "", "FloatBorder" }, -} - -diagnostic.diagnostic = { - virtual_text = true, - update_in_insert = true, - underline = true, - severity_sort = false, - signs = { - active = { - { name = "DiagnosticSignError", text = "" }, - { name = "DiagnosticSignWarn", text = "" }, - { name = "DiagnosticSignHint", text = "" }, - { name = "DiagnosticSignInfo", text = "" }, - }, - }, - float = { - focusable = true, - style = "minimal", - border = diagnostic.border, - source = "always", - header = "", - prefix = "", - }, -} - -function diagnostic.setup() - vim.diagnostic.config(diagnostic.diagnostic) - for _, sign in ipairs(diagnostic.diagnostic.signs.active) do - vim.fn.sign_define(sign.name, { - texthl = sign.name, - text = sign.text, - numhl = "", - }) - end -end - -return diagnostic
M
lua/core/options.lua
@@ -1,6 +1,16 @@
-require("core.diagnostic").setup() +vim.opt.shell = "/bin/bash" -- fixes issues with fish shell -vim.opt.shell = "/bin/bash" -- fixes issues with fish shell +vim.diagnostic.config { + update_in_insert = true, + signs = { + text = { + [vim.diagnostic.severity.ERROR] = "", + [vim.diagnostic.severity.WARN] = "", + [vim.diagnostic.severity.HINT] = "", + [vim.diagnostic.severity.INFO] = "", + }, + }, +} -- leader vim.g.mapleader = " "