From b65411cedfc729cec5ae668abdd523f5cb0613c4 Mon Sep 17 00:00:00 2001 From: lighttpd Date: Fri, 8 May 2020 20:00:20 +0200 Subject: [PATCH] run script once per hour, summary message at 6:00am --- scripts/cryptoAnalyze.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/scripts/cryptoAnalyze.sh b/scripts/cryptoAnalyze.sh index 5d34846..ebf163f 100755 --- a/scripts/cryptoAnalyze.sh +++ b/scripts/cryptoAnalyze.sh @@ -1,5 +1,6 @@ #!/bin/sh +HOUR=$(date +%H) IFS=";" while read DATE CURRENCY COIN PRICE FEE BUYRATE; do @@ -29,6 +30,8 @@ do echo "[$CURRENCY] profit: $curProfit EUR\n => sell?" fi fi - - echo "[$CURRENCY] profit: $curProfit EUR" + if [ "0$HOUR" -eq "6" ]; + then + echo "[$CURRENCY] profit: $curProfit EUR" + fi done < $1