From 1cd182b3a99d6ec9d6e92c6275def0b9eb6889df Mon Sep 17 00:00:00 2001 From: Hyperling Date: Tue, 14 Oct 2025 15:13:24 -0700 Subject: [PATCH] Rename cronjob.sh to check_git.sh. Eventually do the same with the photo checker code so that it can be called from check_git. --- cronjob.sh => check_git.sh | 1 + run.sh | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) rename cronjob.sh => check_git.sh (96%) diff --git a/cronjob.sh b/check_git.sh similarity index 96% rename from cronjob.sh rename to check_git.sh index 08fd0b3..be2586d 100755 --- a/cronjob.sh +++ b/check_git.sh @@ -27,6 +27,7 @@ function kill-project { function reload-project { # Not much to do, run.sh and main.js automatically uses the latest files. rm -v files/photos/index.html + # TBD/TODO: Call check_photos.sh once it has been pulled from run.sh. log "Project reloaded successfully!" } diff --git a/run.sh b/run.sh index 2ffa7fa..bd972e7 100755 --- a/run.sh +++ b/run.sh @@ -123,6 +123,7 @@ log "Removing old index files." find files/photos/ -name "*".html -print -delete { check_main photos + # TBD/TODO: Move this section to check_photos.sh similar to check_git.sh. count=1 http_code=0 port="${ports%% *}" @@ -148,10 +149,10 @@ find files/photos/ -name "*".html -print -delete ## Main ## -log "Start local cronjob." +log "Start check_git." while true; do - check_main cronjob - $DIR/cronjob.sh + check_main check_git + $DIR/check_git.sh sleep 30 done &