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

Re: Wish for rprompt feature



On Mar 20,  7:12pm, Thorsten Kampe wrote:
} 
} Customising your prompt so that it works like rprompt plus the "[...]"
} would require zsh skills beyond mine.

It'd require skills beyond mine, too, without modifying the C code.  As
usual with zsh prompts, RPS1 is computed exactly once (before the line
editor starts up for each command) and thereafter the code only knows
how long it is, to know when the input line overlaps with it and hence
to stop showing it.

However, try this (requires 4.2.0) and see what you think:

zle-line-init() {
  POSTDISPLAY="  ${(%)RPS1}"
}
zle -N zle-line-init

Adjust spacing as you see fit.



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