feat: add cron setup instructions for unattended scheduling of ba_cron_run.sh

This commit is contained in:
Nik Afiq 2026-08-01 21:49:02 +09:00
parent a15ac6111e
commit 7f408c1ad1

View File

@ -80,3 +80,23 @@ echo "Run 'source ~/.bashrc' or open a new shell to pick up completion"
echo "== Done =="
echo "Run with: $REPO_DIR/ba_dailies.sh [mailbox|cafe|stamina|story_sweep|shop_common|shop_tactical|lesson]"
echo "(requires the game already running, window titled 'BlueArchive')"
echo ""
echo "== Cron (optional, not installed by this script) =="
echo "This script does NOT touch crontab -- it's host-level scheduled state, not"
echo "checkout content, and mutating it isn't safe to run unconditionally on every"
echo "re-run of this script the way the venv/tool checks above are. To wire up"
echo "unattended scheduling yourself, run 'crontab -e' and add lines like:"
echo ""
echo " 30 3 * * * $REPO_DIR/ba_cron_run.sh daily"
echo " 30 4 * * * $REPO_DIR/ba_cron_run.sh daily"
echo " 0 1,5,9,13,17,21 * * * $REPO_DIR/ba_cron_run.sh q4h"
echo ""
echo "(times are this host's local system time; presets are defined in"
echo "ba_daily.py's PRESETS dict -- 'daily' and 'q4h' above are examples, not"
echo "the only valid names). Always call ba_cron_run.sh, never ba_dailies.sh"
echo "directly from cron -- it wraps the run in a flock so overlapping fire"
echo "times can't launch concurrent xdotool/scrot sessions against the same"
echo "game window, and logs each run to ~/ba_logs/<preset>.log."
echo "Check crontab -l afterward to confirm; that output is the source of"
echo "truth for the live schedule, not this script."