diff options
author | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2020-01-03 00:42:52 -0500 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2020-01-02 21:42:52 -0800 |
commit | 77b61cb0dff55318fdec9e28ccbaedd051996c5a (patch) | |
tree | ac8d5d31b3c765dd9b4fa9024c82f1d9a538d73d | |
parent | 0c436559dfba9e0bb7e6ce5a835ed8eee540205f (diff) | |
download | rneovim-77b61cb0dff55318fdec9e28ccbaedd051996c5a.tar.gz rneovim-77b61cb0dff55318fdec9e28ccbaedd051996c5a.tar.bz2 rneovim-77b61cb0dff55318fdec9e28ccbaedd051996c5a.zip |
option: restore termencoding (readonly) #11662
'termencoding' option was removed in abaabd1d03fd723630f6addeadee9928faa4cdde
but some plugins check its value.
-rw-r--r-- | src/nvim/option.c | 7 | ||||
-rw-r--r-- | src/nvim/testdir/test_python3.vim | 1 |
2 files changed, 7 insertions, 1 deletions
diff --git a/src/nvim/option.c b/src/nvim/option.c index de25ee3218..a8a4ad6484 100644 --- a/src/nvim/option.c +++ b/src/nvim/option.c @@ -4737,6 +4737,13 @@ bool get_tty_option(char *name, char **value) return true; } + if (strequal(name, "tenc") || strequal(name, "termencoding")) { + if (value) { + *value = xstrdup("utf-8"); + } + return true; + } + if (strequal(name, "ttytype")) { if (value) { *value = p_ttytype ? xstrdup(p_ttytype) : xstrdup("nvim"); diff --git a/src/nvim/testdir/test_python3.vim b/src/nvim/testdir/test_python3.vim index 948ef0a07f..d0f80b8958 100644 --- a/src/nvim/testdir/test_python3.vim +++ b/src/nvim/testdir/test_python3.vim @@ -174,7 +174,6 @@ func Test_Catch_Exception_Message() endfunc func Test_unicode() - throw 'skipped: Nvim does not support "termencoding" option and only supports "utf-8" for "encoding" option' " this crashed Vim once if &tenc != '' throw "Skipped: 'termencoding' is not empty" |