mirror of https://gitlab.com/baco/dotconf.git
fix: Add group to autocmd (to be able to clear it)
Also added some nice border style to the diagnostics pop-up.
This commit is contained in:
parent
82697ea146
commit
8af69b9d0a
|
@ -46,7 +46,12 @@ lua << EOF
|
|||
local nvim_lsp = require("lspconfig")
|
||||
|
||||
local on_attach = function(client, bufnr)
|
||||
vim.diagnostic.config({
|
||||
float = { border = "rounded" }
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd("CursorHoldI", {
|
||||
group = vim.api.nvim_create_augroup("Diagnostics", { clear = true }),
|
||||
buffer = bufnr,
|
||||
callback = function()
|
||||
vim.diagnostic.open_float({ focusable = false, header = "" })
|
||||
|
|
Loading…
Reference in New Issue