From 3954537b9e243fb3df3672d47fe3d9529fa4e544 Mon Sep 17 00:00:00 2001 From: Gregory Anders Date: Mon, 16 Aug 2021 14:05:24 -0600 Subject: [PATCH] feat(defaults): remove 'options' from viewoptions #15397 ref #6289 --- runtime/doc/options.txt | 2 +- runtime/doc/vim_diff.txt | 2 +- src/nvim/options.lua | 2 +- src/nvim/testdir/setup.vim | 1 + 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 4f54e71d79..c3618328aa 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -6700,7 +6700,7 @@ A jump table for the options with a short description can be found at |Q_op|. security reasons. *'viewoptions'* *'vop'* -'viewoptions' 'vop' string (default: "folds,options,cursor,curdir") +'viewoptions' 'vop' string (default: "folds,cursor,curdir") global Changes the effect of the |:mkview| command. It is a comma separated list of words. Each word enables saving and restoring something: diff --git a/runtime/doc/vim_diff.txt b/runtime/doc/vim_diff.txt index 51159b9840..ecc3f52077 100644 --- a/runtime/doc/vim_diff.txt +++ b/runtime/doc/vim_diff.txt @@ -61,8 +61,8 @@ the differences. - 'tags' defaults to "./tags;,tags" - 'ttimeoutlen' defaults to 50 - 'ttyfast' is always set -- 'viewoptions' includes "unix,slash" - 'undodir' defaults to ~/.local/share/nvim/undo (|xdg|), auto-created +- 'viewoptions' includes "unix,slash", excludes "options" - 'viminfo' includes "!" - 'wildmenu' is enabled - 'wildoptions' defaults to "pum,tagfile" diff --git a/src/nvim/options.lua b/src/nvim/options.lua index 585f8d638a..8c0970c32e 100644 --- a/src/nvim/options.lua +++ b/src/nvim/options.lua @@ -2705,7 +2705,7 @@ return { type='string', list='onecomma', scope={'global'}, deny_duplicates=true, varname='p_vop', - defaults={if_true={vi="folds,options,cursor,curdir"}} + defaults={if_true={vi="folds,cursor,curdir"}} }, { -- Alias for "shada". diff --git a/src/nvim/testdir/setup.vim b/src/nvim/testdir/setup.vim index b15df2ea03..57ba57a3c8 100644 --- a/src/nvim/testdir/setup.vim +++ b/src/nvim/testdir/setup.vim @@ -21,6 +21,7 @@ set undodir^=. set wildoptions= set startofline set sessionoptions+=options +set viewoptions+=options set switchbuf= " Unmap Nvim default mappings.