I use this version
VIM - Vi IMproved 8.2 (2019 Dec 12 kompiliert am Aug 29 2020 14:11:37)
Inklusive der Patches: 1-1539
Verändert von jonathon.fernyhough@york.ac.uk
Übersetzt von jonathon.fernyhough@york.ac.uk
under Ubuntu 18.04:
Distributor ID: Ubuntu
Description: Ubuntu 18.04.5 LTS
Release: 18.04
Codename: bionic
Since a couple of days, my console get's garbled with strange chars like this:
wolfgang@cato:~$ gvim
[>4;m[>4;2mwolfgang@cato:~$
If I use the internal gvim console (:shell) it's pretty useless, since everything I type in is broken with strange char sequences.
I tried to track down the problem. It does not occur with an empty .vimrc. What I found out was that if my .vimrc contains only one single line:
let hostname = substitute(system('hostname'), '\n', '', '')
, this seems to be enough to cause the effect. If I change this to the (useless) line
let hostname = substitute('cato', '\n', '', '')
the effect is gone. So I guess it has something to do with the system() call.
Any idea what could cause this behaviour and how it might get fixed?
TERMmight be misconfigured. Try to add this in your vimrc:let [&t_TI, &t_TE] = ['', '']. Or fix yourTERM. – user938271 Sep 05 '20 at 12:39!flag in'guioptions'; like thisset guioptions+=!. – user938271 Sep 05 '20 at 12:43xterm-256colorfor a gnome terminal. If I start from a real xterm, everything is fine. Also,export TERM=fixes the problem in a gnome terminal. – slash Sep 05 '20 at 23:41set guioptions+=!also fixed the garbled internal console, thank you very much! – slash Sep 05 '20 at 23:44