From bb61cf57b0186329f244954db3998d9d40d40a14 Mon Sep 17 00:00:00 2001 From: Wojciech Kozlowski Date: Sun, 15 Nov 2020 21:51:24 +0100 Subject: [PATCH] Fix issue with bash interpreting numbers as octals --- b2-backup.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/b2-backup.sh b/b2-backup.sh index c3048e0..a052352 100755 --- a/b2-backup.sh +++ b/b2-backup.sh @@ -16,7 +16,7 @@ DIRNAME=$(dirname $SCRIPT) # ----------------------------------------------------------------------------- # Run only if it's the first week of the month. # ----------------------------------------------------------------------------- -day_of_month=`date '+%d'` +day_of_month=`date '+%d' | bc` if (( $day_of_month > 7 )) then echo -e "${CYAN}[${SCRIPT}] No B2 backup this week ${NC}"