Don't add icon separator if there is no icon for a status module (#265)

Implemented with advice of @vdbe

Co-authored-by: Aleksandr Jakusev <no@email.com>
This commit is contained in:
j-xella 2024-08-09 20:20:58 +01:00 committed by GitHub
parent e2a1043f42
commit df238924bc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -40,5 +40,9 @@ build_status_module() {
local show_left_separator="#[fg=$color,bg=default,nobold,nounderscore,noitalics]$status_left_separator"
fi
if [ -z "$icon" ] ; then
show_icon=""
fi
echo "$show_left_separator$show_icon$show_text$show_right_separator"
}