.config/nvim/lua/config/autocmds.lua

changeset 1161
2543467f42da
parent 1159
9a19621f294c
child 1165
840f0fde07e2
equal deleted inserted replaced
1160:28e64ed03c25 1161:2543467f42da
48 48
49 -- >> simple highlight conflict markers 49 -- >> simple highlight conflict markers
50 autocmd(g, "BufReadPost", "*", function() 50 autocmd(g, "BufReadPost", "*", function()
51 fn.matchadd("Error", [[\m^\([<>|]\)\{7} \@=\|^=\{7}$]]) 51 fn.matchadd("Error", [[\m^\([<>|]\)\{7} \@=\|^=\{7}$]])
52 end) 52 end)
53
54 -- >> Prune old backup and undo files at startup
55 autocmd(g, "User", "VeryLazy", function()
56 local prune_files = require("config.util").prune_files
57 if vim.go.swapfile then prune_files(vim.go.directory, 90) end
58 if vim.go.backup then prune_files(vim.go.backupdir, 90) end
59 if vim.go.undofile then prune_files(vim.go.undodir, 90) end
60 end)
61

mercurial