[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: I'm confused about TERMCAP

From: Richard Bronosky
Subject: Re: I'm confused about TERMCAP
Date: Fri, 23 Mar 2007 10:47:27 -0400

In my .bashrc I check to decide whether or not to launch screen. The solution I found to work for me is...
    termcap xterm-color
    term "screen"
    set term=xterm-color

I want to know, and want my apps to know, that the terminal IS screen.  I need to make sure my terminal behaves like xterm-color.  I need the apps to know that the terminal behavior and capabilities are that of xterm-color.  I've found that if you keep those 2 simple principles in mind, you can make things work. 1. Make you terminal (keyboard input and textual display) send and receive in a consistent manner.  2. Make sure your apps are treating your terminal accordingly.

You may get lucky and "nuke" variables and have the fallback settings work for you.  But, if you decide on a protocol and get all parties to adhere, you are more likely to succeed.  I didn't get that until I started this thread.

Thank you all.

On 3/13/07, Michael Parson <address@hidden> wrote:
On Tue, Mar 13, 2007 at 11:43:49AM -0400, Andy Harrison wrote:
> On 3/11/07, Joe Zbiciak <address@hidden>wrote:
>> Ok, I might be stepping out of line here, but...  The solution is to nuke
>> TERMCAP when it's a TERMCAP from screen?
>> Why does this feel wrong?
> It's the only way I can correct all the various instances of bad behavior
> caused by running screen.  For example, (the most infuriating for me) when I
> run vi, I can't use the colon key.  When I press it, it's as if I pressed j
> to move the cursor down.  Since I use vi constantly, this is unacceptable.
> In my .vimrc I can literally 'bind : :' to fix that particular behavior, but
> I use vi(m) on too many different systems to hassle with this.
> I always assumed it was some inherent unfriendliness between screen and
> tcsh, since that's the most consistent presence in my environment.  The
> strange behavior also changes depending on which term app I'm using (aterm,
> xterm, eterm, konsole, etc...).  Changing my TERM variable to other values
> didn't help adequately.  I never bothered to research it further once I
> figured out that scrapping the termcap cured everything.

TERM and TERMCAP are related, if your TERM is detected correctly at
login time, you TERMCAP should be set properly too.  If you don't have
the 'screen' termcap/info stuff installed on all the systems you might
be logging into, starting screen with the -Tvt220 (or xterm, or whatever
your preference) will do the right thing (I use bash, so adjust if you
use a csh variant):

$ type -a screen
screen is aliased to `screen -T vt220'
screen is /usr/local/bin/screen

$ echo $TERM

$ echo $TERMCAP
SC|vt220|VT 100/ANSI X3.64 virtual terminal:....

Michael Parson

screen-users mailing list

.!# RichardBronosky #!.
reply via email to

[Prev in Thread] Current Thread [Next in Thread]