diff --git a/bin/compose b/bin/compose index 1ec2c1b..c44db97 100755 --- a/bin/compose +++ b/bin/compose @@ -15,7 +15,6 @@ ## From kal-shlib ## -ANSI_ESC=$'\e[' hash_get() { if get_path sha256sum >/dev/null; then @@ -73,22 +72,9 @@ ansi_color() { fi fi - if [ "$choice" != "no" ]; then - - SET_COL_CHAR="${ANSI_ESC}${COL_CHAR}G" - SET_COL_STATUS="${ANSI_ESC}${COL_STATUS}G" - SET_COL_INFO="${ANSI_ESC}${COL_INFO}G" - SET_COL_ELT="${ANSI_ESC}${COL_ELT}G" - - SET_BEGINCOL="${ANSI_ESC}0G" + ANSI_ESC=$'\e[' - UP="${ANSI_ESC}1A" - DOWN="${ANSI_ESC}1B" - LEFT="${ANSI_ESC}1D" - RIGHT="${ANSI_ESC}1C" - - SAVE="${ANSI_ESC}7" - RESTORE="${ANSI_ESC}8" + if [ "$choice" != "no" ]; then NORMAL="${ANSI_ESC}0m" @@ -110,23 +96,8 @@ ansi_color() { DARKCYAN="${ANSI_ESC}0;36m" DARKWHITE="${ANSI_ESC}0;37m" - SUCCESS=$GREEN - WARNING=$YELLOW - FAILURE=$RED - NOOP=$BLUE - ON=$SUCCESS - OFF=$FAILURE - ERROR=$FAILURE - else - SET_COL_CHAR= - SET_COL_STATUS= - SET_COL_INFO= - SET_COL_ELT= - - SET_BEGINCOL= - NORMAL= RED= GREEN= @@ -142,24 +113,15 @@ ansi_color() { DARKBLUE= DARKPINK= DARKCYAN= - - SUCCESS= - WARNING= - FAILURE= - NOOP= - ON= - OFF= - ERROR= + DARKWHITE= fi ansi_color="$choice" - export SET_COL_CHAR SET_COL_STATUS SET_COL_INFO SET_COL_ELT \ - SET_BEGINCOL UP DOWN LEFT RIGHT SAVE RESTORE NORMAL \ - GRAY RED GREEN YELLOW BLUE PINK CYAN WHITE DARKGRAY \ + export NORMAL GRAY RED GREEN YELLOW BLUE PINK CYAN WHITE DARKGRAY \ DARKRED DARKGREEN DARKYELLOW DARKBLUE DARKPINK DARKCYAN \ - SUCCESS WARNING FAILURE NOOP ON OFF ERROR ansi_color + DARKWHITE SUCCESS WARNING FAILURE NOOP ON OFF ERROR ansi_color }