From 3b63636dee52d01b087ee2ba38897cb6224ffd12 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Sun, 6 Mar 2016 18:03:10 +0000 Subject: [PATCH] Added coloured checking message --- functions/command_monitor.sh | 7 ++++--- functions/core_messages.sh | 9 +++++++++ 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/functions/command_monitor.sh b/functions/command_monitor.sh index abe42cf38..066d0dbdf 100644 --- a/functions/command_monitor.sh +++ b/functions/command_monitor.sh @@ -23,7 +23,7 @@ fn_monitor_check_lockfile(){ fn_monitor_check_update(){ # Monitor will not check if update is running. updatecheck=$(ps -ef|grep "${selfname} update"|grep -v grep|wc -l) - if [ "${updatecheck}" != "0" ]; then + if [ "${updatecheck}" >= "1" ]; then fn_print_info_nl "SteamCMD is currently checking for updates" fn_scriptlog "SteamCMD is currently checking for updates" sleep 1 @@ -32,7 +32,8 @@ fn_monitor_check_update(){ } fn_monitor_msg_checking(){ - fn_print_dots "Checking session: CHECKING" + fn_print_dots "Checking session: " + fn_print_checking_eol fn_scriptlog "Checking session: CHECKING" sleep 1 } @@ -70,7 +71,7 @@ fn_monitor_tmux(){ # checks that tmux session is running tmuxwc=$(tmux list-sessions 2>&1|awk '{print $1}'|grep -Ec "^${servicename}:") if [ "${tmuxwc}" == "1" ]; then - fn_print_ok "Checking session" + fn_print_ok "Checking session: OK" fn_print_ok_eol_nl fn_scriptlog "Checking session: OK" # runs gsquery check on game with specific engines. diff --git a/functions/core_messages.sh b/functions/core_messages.sh index 5e2b269f3..54b245193 100644 --- a/functions/core_messages.sh +++ b/functions/core_messages.sh @@ -176,6 +176,15 @@ fn_print_querying_eol_nl(){ echo -e "\e[0;36mQUERYING\e[0m" } +# CHECKING for end of line +fn_print_checking_eol(){ + echo -en "\e[0;36mCHECKING\e[0m" +} + +fn_print_checking_eol_nl(){ + echo -e "\e[0;36mCHECKING\e[0m" +} + # CANCELED for end of line fn_print_canceled_eol(){ echo -en "\e[0;33mCANCELED\e[0m"