Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

zsh - hpux 11i prompt does not work



Hi,

I use zsh on hpux. I have noticed a problem with zsh and hpux version
11i. I have tried zsh versions 3.0.5 and 4.0.4 with the same results.
Both versions display the problem mentioned below on hpux 11i and both
don't have the problem on hpux 10.20.

I use the dtterm terminal. The same behavior is seen with xterm. What
happens is that I set my PS1 to do a couple of things:
a) Print the hostname, username and pwd on the title bar of the
terminal.
b) Change the color to something other than the default (for dtterm, I
prefer yellow in the example below). Print pwd, last exit value, and
change the color back to default.

However, I notice that most of the prompt settings don't take effect.
Here is a cut and paste from my dtterm window:
 echo $PS1 | xd -c
0000000  %  { 1b  ]  0  ;  %  n  @  %  M 07  %  }  %  {
0000010 1b  [  1  ;  3  3  m  %  }  %  3  ~  -  %  ?  %
0000020  #  %  { 1b  [  m  %  }    \n
000002a
 echo $TERM
dtterm
 pwd
/home/manish

(The terminal window title does not change, it always displays the
default `Terminal').

As you can see, my PS1 is set up to do a bunch of things. Nothing of it
gets printed as part of the prompt. there is no prompt string at all.

I have also noticed that if I change to a directory that has a long name
(i.e. the prompt string expansion becomes very big), then the prompt
does display a portion of itself:

 cd /home/manish/work/hp/tests/MAS/Performance/ 
/MAS/Performance-0% 

which leads me to think that somehow only the last few characters of the
expansion of the prompt are being printed by zsh. Also, if I do a:
/MAS/Performance-0% print -P $PS1
tests/MAS/Performance-0% 
/MAS/Performance-0% 

The line printed by `print -P' (tests/MAS/Performance-0%) is in yellow
as PS1 wanted it to be. Also, the print -P causes the title bar to
change to `manish@tsx2' (manish is my login name , tsx2 is my hostname)
also as PS1 dictates.

Any suggestions as to what could be going wrong / what I could do to
investigate further / what information I should provide to help you
figure what is going on?

Thanks.

-- Manish
____________________________________________________________________
If it weren't for C, we'd be programming in BASI, PASAL, and OBOL.



Messages sorted by: Reverse Date, Date, Thread, Author