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

Re: forwarded message



Richard Coleman wrote:
>set prompt="%{\033]2;%n@%M:%/ - %l\007\033]1;%l@%m\007%}%h [%T] %B%n%b@%m:%B%.2%#%b "
>
>to set my xterm icon name & title and prompt.
>
>If I try to use the same kind of strings for zsh, the %{...%} doesn't seem
>to be really interpreted as I'd expect and I get this:
>
>\033]2;roberto@xxxxxxxxxxxxxxxxx:/build/zsh-3.1.1 - p2\007\033]1;p2@keltia\007203 [20:14] roberto@keltia:zsh-3.1.12% 

The %{...%} is working just fine.  The problem is sequences like "\033",
which have no special meaning in PS1.  You need to put a literal escape
character into PS1.

-zefram



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