run-nightly.sh: use argument '1' to run once

This commit is contained in:
Jens Petersen 2024-12-09 12:04:10 +05:30
parent f61c73d3db
commit 93797bf862

View File

@ -2,12 +2,17 @@
cd "$(dirname "${BASH_SOURCE[0]}")"
case $1 in
1) once=1 ;;
*) cmd=$1
esac
while true; do
git pull
./build.sh nightly-$(date -u +%F) $1
${1:+exit 0}
./build.sh nightly-$(date -u +%F) $cmd
${cmd:+exit 0}
date
${once:+exit 0}
sleep 60m
echo
done