Skip to content

Commit

Permalink
update_latest.sh: copy all json files
Browse files Browse the repository at this point in the history
Since it is not just latest.json that gets updated now, use a glob to
copy all json files from the public directory.
  • Loading branch information
psvenk committed Dec 15, 2024
1 parent c5416b2 commit 1e9acae
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions deploy/cron_scripts/update_latest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ set -e
REPO_DIR="/afs/sipb.mit.edu/project/hydrant/hydrant"

# The output directory, i.e. the one that has the folder being served to the
# internet. In the locker, this is ~/web-scripts/hydrant.
# internet. In the locker, this is ~/web_scripts/hydrant.
OUT_DIR="/afs/sipb.mit.edu/project/hydrant/web_scripts/hydrant"

cd "$REPO_DIR/scrapers"
Expand All @@ -23,7 +23,7 @@ git pull -q
# The scripts machine we use has Python 3.7, so use that.
# This updates $OUT_FILE.
python3.7 update.py
OUT_FILE="$REPO_DIR/public/latest.json"
OUT_FILE="$REPO_DIR/public/*.json"

# Copy $OUT_FILE to the output directory, so it can be served to the internet.
cp "$OUT_FILE" "$OUT_DIR"
cp $OUT_FILE "$OUT_DIR"

0 comments on commit 1e9acae

Please sign in to comment.