Powerlevel9k / powerlevel9k

Powerlevel9k was a tool for building a beautiful and highly functional CLI, customized for you. P9k had a substantial impact on CLI UX, and its legacy is now continued by P10k.
https://github.com/romkatv/powerlevel10k
MIT License
13.46k stars 949 forks source link

[Bugfix] Make icons appear properly. #1338

Closed goddessfreya closed 5 years ago

goddessfreya commented 5 years ago

This was originally only happening to the blue bar, but when I rebased this commit against the most recent commit on next it had actually regressed!

Anyways, pictures are worth a thousand words.

P9K_MULTILINE_LAST_PROMPT_PREFIX_ICON="%K{004}%F{000} %D{\uF017 %H:%M \uF073 %d.%m.%y} %f%k%F{004} %f"
P9K_TIME_FORMAT="%D{\uF017 %H:%M \uF073 %d/%m/%y}"

next from yesterday:

next from today:

next with this PR:

Signed-off-by: Hal Gentz zegentzy@protonmail.com

Edit: Note: I normally only have the blue one, not the white one. I just added it for reference.

goddessfreya commented 5 years ago

cc @dritter

dritter commented 5 years ago

Hmm. The workaround for this would be to use the decomposed UTF-8 Chars directly.. This would avoid the subshell: P9K_TIME_FORMAT="%D{ %H:%M  %d/%m/%y}"

Does this work for you? And sorry for the inconvenience.

goddessfreya commented 5 years ago

Good enough for me. I think a lot of https://github.com/bhilburn/powerlevel9k/wiki/Show-Off-Your-Config will need updating, as this was previously functional on master.

dritter commented 5 years ago

Yeah. There is maybe a better solution if we try to decompose chars on initialization. I'll think about this in the next days. Thanks for letting me know.