开发者

What setting will prevent "vi" to show the editing window after exiting?

开发者 https://www.devze.com 2023-03-05 09:00 出处:网络
I tried to search the answer, but maybe I\'m phrasing the question wrong, I couldn\'t find 开发者_开发问答it.

I tried to search the answer, but maybe I'm phrasing the question wrong, I couldn't find 开发者_开发问答it.

So, in my own Linux environment, when I exit "vi", the content of the editing window stays in the shell window. I cannot just scroll up to see the previous commands I typed before entering "vi". I've been in some environment (as a different user) where once I exit "vi", the vi command just shows as one regular command line following all the earlier commands I typed. I tried to look for the setting for that behavior, which I liked, but I couldn't. Can someone please help me?


It isn't a vi setting per se; it is in the terminfo entry you use ($TERM). Check on what your other user has set for $TERM, and compare that with what you have set. Then, either change your TERM value, or modify the terminal entry you do use. infocmp decompiles terminal entries; tic compiles them. You can create your own directory to hold the entry if you can't modify the system one (or while you are testing your modifications):

mkdir $HOME/terminfo
export TERMINFO=$HOME/terminfo
tic -o $TERMINFO new.terminfo.src

Etc.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号