Skip to content

Commit

Permalink
Adjust diagnostics
Browse files Browse the repository at this point in the history
Signed-off-by: Zach Leslie <[email protected]>
  • Loading branch information
zachfi committed Sep 17, 2022
1 parent 0bd76ca commit 3b3064d
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 2 deletions.
15 changes: 15 additions & 0 deletions vim/nvim/lua/user/autocommands.lua
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,18 @@ vim.cmd([[
autocmd BufWinEnter Tiltfile setlocal filetype=tiltfile syntax=python
augroup end
]])

vim.api.nvim_create_autocmd("CursorHold", {
buffer = bufnr,
callback = function()
local opts = {
focusable = false,
close_events = { "BufLeave", "CursorMoved", "InsertEnter", "FocusLost" },
border = "rounded",
source = "always",
prefix = " ",
scope = "cursor",
}
vim.diagnostic.open_float(nil, opts)
end,
})
2 changes: 1 addition & 1 deletion vim/nvim/lua/user/lsp/handlers.lua
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ M.setup = function()
end

local config = {
virtual_text = true,
virtual_text = false,
signs = {
active = signs,
},
Expand Down
2 changes: 1 addition & 1 deletion vim/nvim/lua/user/options.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ local options = {
termguicolors = true, -- set term gui colors (most terminals support this)
timeoutlen = 500, -- time to wait for a mapped sequence to complete (in milliseconds)
undofile = true, -- enable persistent undo
updatetime = 300, -- faster completion (4000ms default)
updatetime = 250, -- faster completion (4000ms default)
writebackup = false, -- if a file is being edited by another program (or was written to file while editing with another program), it is not allowed to be edited
expandtab = true, -- convert tabs to spaces
shiftwidth = 2, -- the number of spaces inserted for each indentation
Expand Down

0 comments on commit 3b3064d

Please sign in to comment.