Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: invoking a procedure to print the prompt
Dave Yost wrote:
> I need my prompt to contain one thing in one situation and another
> thing in another situation.
>
> It occurs to me that a more clean and powerful way to implement a
> custom prompt would be via a procedure rather than via the
> traditional prompt string variable substitution syntax.
>
> I can't find a way to do this in the zsh man page.
It should be as simple as setting up a precmd function that defines
PS1. If you are up-to-date you can use a suitable precmd_functions
element.
--
Peter Stephenson <pws@xxxxxxx> Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070
Messages sorted by:
Reverse Date,
Date,
Thread,
Author