diff options
Diffstat (limited to 'lua/alpha')
| -rw-r--r-- | lua/alpha/lsp.lua | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/lua/alpha/lsp.lua b/lua/alpha/lsp.lua index 5133edf..aa06eb3 100644 --- a/lua/alpha/lsp.lua +++ b/lua/alpha/lsp.lua @@ -53,15 +53,18 @@ lsp_installer.on_server_ready(function(server) vim.cmd [[ do User LspAttachBuffers ]] end) -require "lspconfig".efm.setup { - init_options = {documentFormatting = true}, - settings = { - rootMarkers = {".git/"}, - languages = { - blade = { - {formatCommand = "blade-formatter --stdin", formatStdin = true} - }, - json = {} - } + +vim.lsp.handlers["textDocument/publishDiagnostics"] = vim.lsp.with( + vim.lsp.diagnostic.on_publish_diagnostics, { + underline = true, + update_in_insert = false, + virtual_text = { spacing = 2, prefix = "●" }, + severity_sort = true, } -} +) + +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 = "" }) +end |