From 333e04ef45fb149983f2122ad56346fe4761791c Mon Sep 17 00:00:00 2001 From: Hossam Elbadissi Date: Mon, 28 Mar 2022 23:23:02 +0000 Subject: [PATCH] Fixes #1952 This pull request replaces the old broken code (see #1952) with a simpler, working one for `bar_color_total`, just like `bar_color_elapsed`. Let me know if the old code was done that way for a specific purpose. --- neofetch | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/neofetch b/neofetch index 48b96d215..fb4eda1cf 100755 --- a/neofetch +++ b/neofetch @@ -4715,11 +4715,11 @@ set_text_colors() { bar_color_elapsed="$(color "$bar_color_elapsed")" fi - case ${bar_color_total}${1} in - distro[736]) bar_color_total=$(color "$1") ;; - distro[0-9]) bar_color_total=$(color "$2") ;; - *) bar_color_total=$(color "$bar_color_total") ;; - esac + if [[ "$bar_color_total" == "distro" ]]; then + bar_color_total="$(color fg)" + else + bar_color_total="$(color "$bar_color_total")" + fi } color() {