From 226a0d71bb547cc399e00e971789de9b0aceb9f3 Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Tue, 10 Jul 2018 14:48:02 +1200 Subject: Add 'sessionoptions' settings This disables saving global and local options and mappings in the sessions. This is more trouble than it's worth for me, because sessions don't include buffer-local variables, which means that in addition to restoring the state of options and mappings, plugins and filetype plugins are reloaded in the absence of b:loaded_* guards. --- vim/vimrc | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'vim/vimrc') diff --git a/vim/vimrc b/vim/vimrc index 73b71646..d1b47b0b 100644 --- a/vim/vimrc +++ b/vim/vimrc @@ -141,6 +141,12 @@ if has('linebreak') endif endif +" Don't store any options or mappings in sessions +if has('mksession') + set sessionoptions-=localoptions + set sessionoptions-=options +endif + " Let me move beyond buffer text in visual block mode if has('virtualedit') set virtualedit+=block -- cgit v1.2.3