Fuzion Logo
flang.dev — The Fuzion Language Portal
JavaScript seems to be disabled. Functionality is limited.

run_every_day.sh


#!/bin/bash

interval=$((24*60*60)) # seconds, daily
time=$((2*3600+17*60)) # time, 2h17 GMT

for (( ; ; ))
do
now=$(date +%s)
sleep_seconds=$(( $interval - ($now % $interval) + $time))

echo sleep $sleep_seconds seconds
sleep $sleep_seconds
./runall.sh
echo done.
done