bug fix: strip escape sequences in instant prompt output less aggressively

pull/1823/head
Roman Perepelitsa 3 years ago
parent f07d7baea3
commit e13283ec7d

@ -6535,7 +6535,7 @@ function _p9k_clear_instant_prompt() {
unset _z4h_saved_screen unset _z4h_saved_screen
fi fi
print -rn -- $terminfo[rc]${(%):-%b%k%f%s%u}$terminfo[ed] print -rn -- $terminfo[rc]${(%):-%b%k%f%s%u}$terminfo[ed]
local unexpected=${${${(S)content//$'\e[?'<->'c'}//$'\e['<->' q'}//$'\e'[^$'\a\e']#($'\a'|$'\e\\')} local unexpected=${(S)${${content//$'\e[?'<->'c'}//$'\e['<->' q'}//$'\e'[^$'\a\e']#($'\a'|$'\e\\')}
if [[ -n $unexpected ]]; then if [[ -n $unexpected ]]; then
local omz1='[Oh My Zsh] Would you like to update? [Y/n]: ' local omz1='[Oh My Zsh] Would you like to update? [Y/n]: '
local omz2='Updating Oh My Zsh' local omz2='Updating Oh My Zsh'

Loading…
Cancel
Save