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

Prompt width miscomputed with conditional substring



My zsh prompt is:

local ret_status="%(?:%{$fg_bold[green]%}%%:%{$fg_bold[red]%}%%%s)"
PROMPT="%{$fg[red]%}%n%{$reset_color%}@%{$fg[blue]%}%m:%{$fg[yellow]%}%~
%(1j,$fg[cyan][%j],)${ret_status}%{$reset_color%} "

When I have background jobs, the prompt becomes 3 characters longer and
command-line editing seems to wrap at the wrong column.

This is also reproducible with zsh built from git (zsh-5.0.7-374-gd4f50f2).

-- 
 _ // Bernie Innocenti
 \X/  http://codewiz.org



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