delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2000/08/21/07:52:11

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Date: Mon, 21 Aug 2000 07:51:02 -0400
From: Jeffrey Juliano <juliano AT cs DOT unc DOT edu>
Reply-To: juliano AT cs DOT unc DOT edu
To: Andreas Zielke <andreas DOT zielke AT sdm DOT de>
cc: cygwin AT sourceware DOT cygnus DOT com
Subject: setting TERM=cygwin in non-cygwin unix [Was: Re: A bit OT: vi in
telnet session]
In-Reply-To: <14752.62218.287000.937055@gargle.gargle.HOWL>
Message-ID: <Pine.SGI.4.10.10008210728180.380354-100000@evans.cs.unc.edu>
MIME-Version: 1.0

On Mon, 21 Aug 2000, Andreas Zielke wrote:

> I guess this posting is a bit off-topic, but I don't know any news-
> group that would be more appropriate. (If you do, please tell me.)

It can't hurt to get the answer into the mail archive.  This might even be
a FAQ from people learning unix via cygwin.

BTW, the answer applies no only to telnet, but also to ssh, rlogin, etc.


> When I telnet to a machine (running SunOS 5.7), using the telnet-
> program that comes with 1.1.4 Cygwin an start vi I get this error-
> message:
> 
> bash-2.03$ vi
> cygwin: Unknown terminal type
> Visual needs addressable cursor or upline capability

The quick answer is to set your TERM to vt100 or something else that's
pretty close.

The better answer is to make your non-cygwin unix machines aware of the
cygwin TERM type.  There are two ways to do this, depending on if your
unix machine uses termcap or terminfo.

You can get general info about termcap and terminfo by typing 'man
termcap' and 'man terminfo'.  Follow the see-also links for documentation
on the helper programs, including one that converts between termcap and
terminfo sytle information.  Read the manpages; everything you need to
know is there. You may want to ask your sysadmin if your systems use
termcap or terminfo. But they probably use terminfo.

If you use termcap, then you need to add a cygwin entry to the termcap
file.  If you use terminfo, then you need to add a cygwin entry to the
terminfo/c/ directory.

In my environment, we have solaris, irix, hpux, and linux machines.  I
don't have root privilege, so I do this in my home directory and set
TERMINFO env var to point to ~/terminfo.  I've placed into that dir the
terminfo files for any terminal I use.  It looks like this:

~/terminfo/c/cygwin
           i/iris-ansi
           i/iris-ansi-net
           v/vt100
           x/xterm

plus a few others.  Then, my startup files do a

   export TERMINFO=~/terminfo

If you want to be clever, you can set TERMINFO only if your term-type
isn't in the system-wide termfino directory.  That way you ensure that you
use the correct `xterm', if they differ among platforms.

-jeff


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019