diff --git a/scripts-new/lib/logging.sh b/scripts-new/lib/logging.sh index 7e1cf9ba2..cd388671d 100644 --- a/scripts-new/lib/logging.sh +++ b/scripts-new/lib/logging.sh @@ -288,6 +288,9 @@ function openim::log::print_red_no_time_stamp() { echo -e "\033[0;31m$1\033[0m" } +function openim::log::print_green_no_time_stamp() { + echo -e "\033[0;32m$1\033[0m" +} diff --git a/scripts-new/start.sh b/scripts-new/start.sh index 4e7e7d9d7..e4566f1bd 100644 --- a/scripts-new/start.sh +++ b/scripts-new/start.sh @@ -14,16 +14,14 @@ source "$OPENIM_SCRIPTS/bricks.sh" result=$(start_tools) ret_val=$? - - if [ $ret_val -ne 0 ]; then - echo "tools start failed, abort start" - echo "$result" + openim::log::print_red "Some tools failed to start, details are as follows, abort start" + openim::log::print_red_no_time_stamp "$result" exit 1 fi -echo "all tools ok" -echo "$result" +openim::log::print_green "All tools executed successfully, details are as follows:" +openim::log::print_green_no_time_stamp "$result" kill_exist_binaries