summaryrefslogtreecommitdiffstats
path: root/plugin
diff options
context:
space:
mode:
authorThomas Vanbesien <tvanbesi@proton.me>2026-05-22 11:46:08 +0200
committerThomas Vanbesien <tvanbesi@proton.me>2026-05-22 11:46:08 +0200
commit550ba704b6d0fabd3ac0077c2c1067029c8a0264 (patch)
treedd3ae750d505d6d8b10660441f70ab3a4205fa19 /plugin
parente4c6e0bdc40df9f5420eed3f57553f6652cc033f (diff)
downloadnvim-config-550ba704b6d0fabd3ac0077c2c1067029c8a0264.tar.gz
nvim-config-550ba704b6d0fabd3ac0077c2c1067029c8a0264.zip
misc(nvim): reload buffer when its file changed on disk
Bump 'updatetime' to 1 second because it affects three things: - swap file save frequency - GitGutter signs update frequency - CursorHold and CursorHoldI trigger frequency 100ms is too high of a frequency. Enable focus events in tmux for nvim 'FocusGained' event, Add two event handlers, one for updating the buffer with `checktime`, another for logging a message when doing so.
Diffstat (limited to 'plugin')
-rw-r--r--plugin/50-git.lua2
1 files changed, 0 insertions, 2 deletions
diff --git a/plugin/50-git.lua b/plugin/50-git.lua
index 609ab93..64e6cd0 100644
--- a/plugin/50-git.lua
+++ b/plugin/50-git.lua
@@ -4,8 +4,6 @@
vim.pack.add({ "https://github.com/airblade/vim-gitgutter" }) -- Show git status in the gutter
-vim.opt.updatetime = 100 -- How often the git signs in the gutter update in ms
-
vim.keymap.set("n", "<Leader>gt", "<Cmd>GitGutterLineHighlightsToggle<CR>", { desc = "Toggle git line highlighting" })
vim.keymap.set("n", "<Leader>gg", "<Cmd>GitGutter<CR>", { desc = "Refresh GitGutter" })
vim.keymap.set("n", "<Leader>gq", "<Cmd>GitGutterQuickFix<CR>", { desc = "Git hunks to quickfix list" })