zsh-users
 help / color / mirror / code / Atom feed
* Teaching zsh about a term variable?
@ 2004-08-05 20:34 Mac Mason
  2004-08-05 21:37 ` Vincent Lefevre
  0 siblings, 1 reply; 4+ messages in thread
From: Mac Mason @ 2004-08-05 20:34 UTC (permalink / raw)
  To: zsh-users

[-- Attachment #1: Type: text/plain, Size: 842 bytes --]

I recently built and installed zsh-4.2.0 on a Solaris 9 machine.

However, once I chsh'd my shell to zsh, it does this on login:

/home/mac/.zshrc:21: can't find terminal definition for xterm-color
0m?

(where '0m?' is the prompt).

Setting TERM to xterm (mostly) fixes it, but there are some things that
need xterm-color.

Interestingly enough, if I exec() zsh from a standard tcsh session,
xterm-color works just fine, so I know a working def exists; zsh just
don't know where to find it.

So, does anybody know where in the myriad config files I should say
"hey, zsh, look here for more terminal definitons" and what the syntax
of that would be?

Thanks!

    --Mac
-- 
Julian "Mac" Mason                            mac@cs.hmc.edu
Computer Science '06                          (909)-607-3129
Harvey Mudd College

[-- Attachment #2: Type: application/pgp-signature, Size: 185 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Teaching zsh about a term variable?
  2004-08-05 20:34 Teaching zsh about a term variable? Mac Mason
@ 2004-08-05 21:37 ` Vincent Lefevre
  2004-08-06  9:30   ` Peter Stephenson
  0 siblings, 1 reply; 4+ messages in thread
From: Vincent Lefevre @ 2004-08-05 21:37 UTC (permalink / raw)
  To: zsh-users

On 2004-08-05 13:34:46 -0700, Mac Mason wrote:
> So, does anybody know where in the myriad config files I should say
> "hey, zsh, look here for more terminal definitons" and what the syntax
> of that would be?

Perhaps the TERMINFO environment variable?

-- 
Vincent Lefèvre <vincent@vinc17.org> - Web: <http://www.vinc17.org/>
100% validated (X)HTML - Acorn / RISC OS / ARM, free software, YP17,
Championnat International des Jeux Mathématiques et Logiques, etc.
Work: CR INRIA - computer arithmetic / SPACES project at LORIA


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Teaching zsh about a term variable?
  2004-08-05 21:37 ` Vincent Lefevre
@ 2004-08-06  9:30   ` Peter Stephenson
  2004-08-06 14:40     ` Vincent Lefevre
  0 siblings, 1 reply; 4+ messages in thread
From: Peter Stephenson @ 2004-08-06  9:30 UTC (permalink / raw)
  To: zsh-users

Vincent Lefevre wrote:
> On 2004-08-05 13:34:46 -0700, Mac Mason wrote:
> > So, does anybody know where in the myriad config files I should say
> > "hey, zsh, look here for more terminal definitons" and what the syntax
> > of that would be?
> 
> Perhaps the TERMINFO environment variable?

Yes, that's usually the way to go.  Actually, it's probably something
simple if it works in tcsh.  But here's how to set it up from scratch.

I have

export TERMINFO=~/lib/terminfo

and the directory ~/lib/terminfo contains

c v x

with entries for cygwin, vs100 and xterm respectively.  The files are
compiled with `tic' (which uses $TERMINFO to find out where to put the
files).  You can can get a source file from a similar terminal (if you
know what one is) using `infocmp -I similar-term', which you can edit.

Of course, knowing how the terminal works is another matter.  Here's the
source for the xterm entry I use on Solaris which (apparently) supports
colour, output with infocmp -I.

#	Reconstructed via infocmp from file: /home/pws/lib/terminfo/x/xterm
xterm|vs100|xterm terminal emulator,
	am, km, mir, msgr, xenl,
	cols#80, it#8, lines#65,
	acsc=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
	bel=^G, blink=\E[5m, bold=\E[1m, clear=\E[H\E[2J,
	cr=\r, csr=\E[%i%p1%d;%p2%dr, cub=\E[%p1%dD, cub1=\b,
	cud=\E[%p1%dB, cud1=\n, cuf=\E[%p1%dC, cuf1=\E[C,
	cup=\E[%i%p1%d;%p2%dH, cuu=\E[%p1%dA, cuu1=\E[A,
	dch=\E[%p1%dP, dch1=\E[P, dl=\E[%p1%dM, dl1=\E[M,
	ed=\E[J, el=\E[K, el1=\E[1K$<3>, enacs=\E(B\E)0,
	home=\E[H, ht=\t, hts=\EH, ich=\E[%p1%d@, ich1=\E[@,
	il=\E[%p1%dL, il1=\E[L, ind=\n, ka1=\EOq, ka3=\EOs,
	kb2=\EOr, kbs=\b, kc1=\EOp, kc3=\EOn, kcub1=\EOD,
	kcud1=\EOB, kcuf1=\EOC, kcuu1=\EOA, kent=\EOM,
	kf0=\E[21~, kf1=\E[11~, kf10=\EOx, kf2=\E[12~,
	kf3=\E[13~, kf4=\E[14~, kf5=\E[15~, kf6=\E[17~,
	kf7=\E[18~, kf8=\E[19~, kf9=\E[20~, rc=\E8, rev=\E[7m,
	ri=\EM, rmacs=^O, rmkx=\E[?1l\E>, rmso=\E[m,
	rmul=\E[m,
	rs1=\E>\E[1;3;4;5;6l\E[?7h\E[m\E[r\E[2J\E[H, rs2=@,
	sc=\E7,
	sgr=\E[0%?%p1%p6%|%t;1%;%?%p2%t;4%;%?%p1%p3%|%t;7%;%?%p4%t;5%;m%?%p9%t^N%e^O%;,
	sgr0=\E[m, smacs=^N, smkx=\E[?1h\E=, smso=\E[7m,
	smul=\E[4m, tbc=\E[3g,

Here's `infocmp -I xterm-color' from Fedora Core 2.

#       Reconstructed via infocmp from file: /usr/share/terminfo/x/xterm-color
xterm-color|nxterm|generic color xterm, 
        am, xenl, km, mir, msgr, 
        cols#80, it#8, lines#24, colors#8, pairs#64, ncv@, 
        acsc=``aaffggiijjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~, 
        bel=^G, cr=^M, csr=\E[%i%p1%d;%p2%dr, tbc=\E[3g, 
        clear=\E[H\E[2J, el=\E[K, ed=\E[J, cup=\E[%i%p1%d;%p2%dH, 
        cud1=^J, home=\E[H, cub1=^H, cuf1=\E[C, cuu1=\E[A, dch1=\E[P, 
        dl1=\E[M, enacs=\E)0, smacs=^N, bold=\E[1m, 
        smcup=\E7\E[?47h, smir=\E[4h, rev=\E[7m, smso=\E[7m, 
        smul=\E[4m, rmacs=^O, sgr0=\E[m, rmcup=\E[2J\E[?47l\E8, 
        rmir=\E[4l, rmso=\E[m, rmul=\E[m, 
        is2=\E7\E[r\E[m\E[?7h\E[?1;3;4;6l\E[4l\E8\E>, 
        il1=\E[L, kbs=^H, kdch1=\E[3~, kcud1=\EOB, kf1=\E[11~, 
        kf10=\E[21~, kf11=\E[23~, kf12=\E[24~, kf13=\E[25~, 
        kf14=\E[26~, kf15=\E[28~, kf16=\E[29~, kf17=\E[31~, 
        kf18=\E[32~, kf19=\E[33~, kf2=\E[12~, kf20=\E[34~, 
        kf3=\E[13~, kf4=\E[14~, kf5=\E[15~, kf6=\E[17~, kf7=\E[18~, 
        kf8=\E[19~, kf9=\E[20~, kfnd=\E[1~, kich1=\E[2~, 
        kcub1=\EOD, kmous=\E[M, knp=\E[6~, kpp=\E[5~, kcuf1=\EOC, 
        kslt=\E[4~, kcuu1=\EOA, rmkx=\E[?1l\E>, smkx=\E[?1h\E=, 
        op=\E[m, dch=\E[%p1%dP, dl=\E[%p1%dM, cud=\E[%p1%dB, 
        il=\E[%p1%dL, cub=\E[%p1%dD, cuf=\E[%p1%dC, 
        cuu=\E[%p1%dA, 
        rs2=\E7\E[r\E8\E[m\E[?7h\E[?1;3;4;6l\E[4l\E>, rc=\E8, 
        sc=\E7, ind=^J, ri=\EM, setab=\E[4%p1%dm, setaf=\E[3%p1%dm, 
        hts=\EH, ht=^I, u6=\E[%i%d;%dR, u7=\E[6n, u8=\E[?1;2c, 
        u9=\E[c, 

-- 
Peter Stephenson <pws@csr.com>                  Software Engineer
CSR Ltd., Science Park, Milton Road,
Cambridge, CB4 0WH, UK                          Tel: +44 (0)1223 692070


**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.

This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.

www.mimesweeper.com
**********************************************************************


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Teaching zsh about a term variable?
  2004-08-06  9:30   ` Peter Stephenson
@ 2004-08-06 14:40     ` Vincent Lefevre
  0 siblings, 0 replies; 4+ messages in thread
From: Vincent Lefevre @ 2004-08-06 14:40 UTC (permalink / raw)
  To: zsh-users

On 2004-08-06 10:30:07 +0100, Peter Stephenson wrote:
[...]
> with entries for cygwin, vs100 and xterm respectively.  The files are
> compiled with `tic' (which uses $TERMINFO to find out where to put the
> files).  You can can get a source file from a similar terminal (if you
> know what one is) using `infocmp -I similar-term', which you can edit.

Is the -I option needed? I've never used it (but it seems to be the
default here).

-- 
Vincent Lefèvre <vincent@vinc17.org> - Web: <http://www.vinc17.org/>
100% validated (X)HTML - Acorn / RISC OS / ARM, free software, YP17,
Championnat International des Jeux Mathématiques et Logiques, etc.
Work: CR INRIA - computer arithmetic / SPACES project at LORIA


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-08-06 14:44 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-08-05 20:34 Teaching zsh about a term variable? Mac Mason
2004-08-05 21:37 ` Vincent Lefevre
2004-08-06  9:30   ` Peter Stephenson
2004-08-06 14:40     ` Vincent Lefevre

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).