From b3974e4437a0119ca81c926bd2b6549aca509c13 Mon Sep 17 00:00:00 2001 From: Björn Linse Date: Sun, 19 Jan 2020 08:48:35 +0100 Subject: restore old 'termencoding' behavior Partially reverts #11647. Replaces #11662 The old implementation was removed without clear motivation. The "term option" hackaround added in its place is neither shorter nor simpler. The new behavior breaks even init.vim that expliticly check against it: if exists('&termencoding') set termencoding=utf-8 endif There was nothing wrong with the 0.4.x behavior. Empty &tenc has indicated that the &enc value should be used for all the history of Nvim. Ignoring setting the option is the expected behavior for Vim versions that does not support the option (and Nvim is such a version) 'tenc' was also irrelevant to the Test_unicode python3 test. The reason this has to be disabled is that neovim can't change internal 'encoding' --- src/nvim/options.lua | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/nvim/options.lua') diff --git a/src/nvim/options.lua b/src/nvim/options.lua index a5a14a1a25..7d080b8d56 100644 --- a/src/nvim/options.lua +++ b/src/nvim/options.lua @@ -2488,6 +2488,12 @@ return { varname='p_tbidi', defaults={if_true={vi=false}} }, + { + full_name='termencoding', abbreviation='tenc', + type='string', scope={'global'}, + vi_def=true, + defaults={if_true={vi=""}} + }, { full_name='termguicolors', abbreviation='tgc', type='bool', scope={'global'}, -- cgit