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

BUG? - 4.0.2, current 4.1 - blank left prompt & blank line erases right prompt



I wrote "BUG?" instead of "BUG" because this behavior is kind of cute.
Probably it was unintended, however.  And the right thing to do (which
I am NOT volunteering for, since I don't think it's important) is to
add a bunch of options -- transient_prompt, transient_prompt_blank_line,
transient_rprompt_blank_line, etc.

The behavior affects the released 4.0.2, as well as today's daily 4.1
snapshot.  I haven't tested 4.0.4 (it seems not to compile on my system)
but undoubtedly it works the same way.

If the left prompt is empty and you enter a blank line (by simply hitting
return) then the right prompt will be erased.

This is strange in 4.0.2 since it has no transient_rprompt option,
so there's no other way of erasing the right prompt!  With the daily
snapshot the transient_rprompt option is ignored.

The logic for displaying the right prompt (in Src/Zle/zle_refresh.c)
checks trashedzle.  Perhaps the combination of the empty prompt and
empty line means that trashedzle is never set.  (I haven't actually
tested this theory.)  But in that case why does the right prompt get
displayed at all?

-- Derek



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