From a1ee8620aa1788e7afaea93a2531129bc77c13c6 Mon Sep 17 00:00:00 2001 From: Pocco81 Date: Wed, 13 Apr 2022 12:28:01 -0500 Subject: [PATCH] fix: prompt on palettes_gen.sh --- resources/palettes_gen.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/resources/palettes_gen.sh b/resources/palettes_gen.sh index 0b0f6cb..6276277 100755 --- a/resources/palettes_gen.sh +++ b/resources/palettes_gen.sh @@ -119,10 +119,6 @@ function prompt() { local message=${2} local modifiers=${3} - if [[ $1 == "-i" || $1 == "--info" ]]; then - type="" - fi - case ${type} in "-e" | "--error") printf "\033[0;31m${modifiers}ERROR: %s${NC}\n" "${message}" @@ -134,7 +130,11 @@ function prompt() { printf "\033[0;33m${modifiers}WARNING: %s${NC}\n" "${message}" ;; *) - printf "\033[0;34m${modifiers}INFO: %s${NC}\n" "${message}" + if [[ $1 == "-i" || $1 == "--info" ]]; then + type="${message}" + message=${modifiers} + fi + printf "\033[0;34m${message}INFO: %s${NC}\n" "${type}" ;; esac }