neovim: Exclude temp files from persistent undo

Otherwise it is possible to restore cleartext passwords from pass or
sops from the undo files.
This commit is contained in:
Simon Bruder 2022-06-12 21:03:32 +02:00
parent 67b30a52af
commit 2ce6f535d0
Signed by: simon
GPG key ID: 8D3C82F9F309F8EC

View file

@ -41,6 +41,8 @@ cmd('colorscheme solarized')
opt.undofile = true
opt.undolevels = 4096
opt.undoreload = 16384
cmd('autocmd BufWritePre /dev/shm/* setlocal noundofile') -- exclude pass
cmd('autocmd BufWritePre /tmp/* setlocal noundofile') -- exclude sops
-- Behaviour
opt.hidden = true -- background buffers