From 94763c8aef9d34dc8a8dc9aea6835c4a4c2840fb Mon Sep 17 00:00:00 2001 From: Yasin Kaya Date: Wed, 25 Nov 2020 14:42:04 +0300 Subject: [PATCH] Added colored debug messages --- src/functions.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/functions.sh b/src/functions.sh index 23d3885..f54d7cd 100644 --- a/src/functions.sh +++ b/src/functions.sh @@ -2,9 +2,10 @@ source configs.sh -function debug() +function debug { - echo $(date "+%Y/%m/%d - %H:%M:%S :") "$1" + ECHO_PARAM=${2:-''} + echo -e $ECHO_PARAM ${GREEN}$(date "+%Y/%m/%d->${BLUE}%H:%M:%S") ${SET} "$1" } function check_network()