From 9f216cb5c8f8ac986a8f2bbb8b90d15ce3428f27 Mon Sep 17 00:00:00 2001 From: c032 Date: Fri, 26 Jul 2024 15:59:47 +0000 Subject: [PATCH] Prefer downloading `.json.lz4` --- .github/workflows/daily-update.yml | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/.github/workflows/daily-update.yml b/.github/workflows/daily-update.yml index a4bb41d..65e3d9e 100644 --- a/.github/workflows/daily-update.yml +++ b/.github/workflows/daily-update.yml @@ -3,6 +3,9 @@ name: "daily-update" on: schedule: - cron: "15 5 * * *" + push: + paths: + - ".github/**" jobs: daily-update: @@ -22,7 +25,7 @@ jobs: run: | pip install -r requirements.txt - - name: "Download `animetitles.json`" + - name: "Download `animetitles.json.lz4`" run: | mkdir -p 'data' @@ -37,9 +40,12 @@ jobs: curl \ --verbose \ --fail --fail-early \ - --compressed \ - 'https://ddl.c032.dev/anidb/animetitles.json' - ) > 'data/animetitles.json' + 'https://ddl.c032.dev/anidb/animetitles.json.lz4' + ) > 'data/animetitles.json.lz4' + + - name: "Decompress `animetitles.json.lz4`" + run: | + lz4 -d --rm 'data/animetitles.json.lz4' - name: "Sanity check" run: | @@ -54,4 +60,4 @@ jobs: run: | git add --all -v 'data" git commit -m 'Daily update' - git push origin main + git push 'origin' 'main'