nvim: use float for diagnostics
Anirudh Oppiliappan x@icyphox.sh
Fri, 11 Mar 2022 21:06:10 +0530
3 files changed,
13 insertions(+),
2 deletions(-)
M
config/nvim/init.lua
→
config/nvim/init.lua
@@ -25,7 +25,6 @@ require('treesitter')
require('fzy/fzy') -- lsp setup --- require('lsp.yaml') shits too noisy --- require('lsp.lua') it's horrible +require('lsp.config') require('lsp.python') require('lsp.go')
A
config/nvim/lua/lsp/config.lua
@@ -0,0 +1,11 @@
+vim.diagnostic.config({ + virtual_text = false, + signs = true, + underline = true, + update_in_insert = true, + severity_sort = false, +}) + +-- hover for diagnostic +vim.opt.updatetime = 250 +vim.cmd [[autocmd! CursorHold,CursorHoldI * lua vim.diagnostic.open_float(bor, {focus=false, border='rounded'})]]
M
config/nvim/lua/settings.lua
→
config/nvim/lua/settings.lua
@@ -28,6 +28,7 @@ o.showmode = true
o.listchars='tab:│ ,nbsp:␣,trail:·,extends:>,precedes:<' o.hidden = true o.completeopt = { 'menuone', 'noselect', 'noinsert' } +o.signcolumn = 'yes:2' o.wildignore = [[ .git,.hg,.svn *.aux,*.out,*.toc