putzen.sh: fix calender weeks > 7

This commit is contained in:
lemoer 2025-02-18 20:55:38 +01:00
parent d18f93e369
commit 74ce768d70

View File

@ -7,7 +7,7 @@ else
week=$1
fi
current_week=$(date +%V)
current_week=$(date +%V | sed s/^0//) # sed is to remove leading zeros to avoid interpreting as octal number in next line
next_week=$((current_week + 1))
if [ "$next_week" -gt 52 ]; then
next_week=1