We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2b909ec commit 36797a3Copy full SHA for 36797a3
1 file changed
root/etc/s6-overlay/s6-rc.d/init-modmanager-config/run
@@ -5,6 +5,16 @@ CRON_MINS=$((0 + RANDOM % 59))
5
6
sed -i "s/@@MINUTES@@/${CRON_MINS}/" /etc/crontabs/root
7
8
-echo "[mod-init] Mod updates will run every 6 hours at ${CRON_MINS} minutes past the hour"
+if [[ $(date "+%H") -gt 0 && $(date "+%H") -lt 6 ]]; then
9
+ NEXT_HOUR=6
10
+elif [[ $(date "+%H") -gt 6 && $(date "+%H") -lt 12 ]]; then
11
+ NEXT_HOUR=12
12
+elif [[ $(date "+%H") -gt 12 && $(date "+%H") -lt 18 ]]; then
13
+ NEXT_HOUR=18
14
+else [[ $(date "+%H") -gt 18 && $(date "+%H") -le 23 ]];
15
+ NEXT_HOUR=0
16
+fi
17
+
18
+echo "[mod-init] Mod updates will run every 6 hours at ${CRON_MINS} minutes past the hour. Next update will be at ${NEXT_HOUR}:${CRON_MINS}."
19
20
/app/update-mods.sh
0 commit comments