From e333169211b84d6f4012ac9e40bcbbf370b74289 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=CE=9Blisue?= Date: Sat, 7 Dec 2024 02:02:40 +0900 Subject: [PATCH] Remove `nobackup` option (#86) Close #85 The `backup` (and `nobackup`) option is global and not local to the buffer so this change affects all buffers. This is not the intended. Note that it seems the `backup` option does not have any effect while suda write the file through `BufWriteCmd`. So this simple change should not affect the security of the plugin. --- autoload/suda.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/autoload/suda.vim b/autoload/suda.vim index 9b58ea8..8cf6409 100644 --- a/autoload/suda.vim +++ b/autoload/suda.vim @@ -186,7 +186,7 @@ function! suda#BufReadCmd() abort \}) silent 0delete _ setlocal buftype=acwrite - setlocal nobackup noswapfile noundofile + setlocal noswapfile noundofile setlocal nomodified filetype detect redraw | echo echo_message