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

Prompt for ZSH



Hi,

Recently I switched from bash to zsh. One thing that is _not_ working so far is my old colored command prompt. I converted it to zsh and it looks like:

export PS1="$(print ${dark_gray})[$(print ${blue})%n$(print ${dark_gray})@$(print ${purple})%m$(print ${dark_gray})|$(print ${none})%1~$(print ${purple})>$(print ${none})"

But this command prompt has a problem with linebreak, as it is too long for one line because of the escape sequences. In bash this issue could be solved with something like

\[$COLOR\]

How to do this in zsh?

/BR:
   Gerolf



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