From 6dcf5ea0ea149ecb4182f07b24a9fa781b12ca8e Mon Sep 17 00:00:00 2001 From: shimomo Date: Sun, 31 Aug 2025 13:54:20 +0900 Subject: [PATCH 1/3] ci: fetch full git history in checkout step for reliable rebase --- .github/workflows/cron.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/cron.yml b/.github/workflows/cron.yml index 8445bcfa..f60ea18e 100644 --- a/.github/workflows/cron.yml +++ b/.github/workflows/cron.yml @@ -21,6 +21,8 @@ jobs: - name: Checkout Code uses: actions/checkout@ff7abcd0c3c05ccf6adc123a8cd1fd4fb30fb493 + with: + fetch-depth: 0 - name: Install base dependencies (without scraper) run: | From 7e5a8a3575d6c66e439ab9373a5539ce61c554bd Mon Sep 17 00:00:00 2001 From: shimomo Date: Sun, 31 Aug 2025 14:14:45 +0900 Subject: [PATCH 2/3] ci: prevent concurrent runs with concurrency group --- .github/workflows/cron.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/cron.yml b/.github/workflows/cron.yml index f60ea18e..f372c18e 100644 --- a/.github/workflows/cron.yml +++ b/.github/workflows/cron.yml @@ -5,6 +5,10 @@ on: - cron: '0,30 * * * *' workflow_dispatch: +concurrency: + group: cron-${{ github.ref }} + cancel-in-progress: false + permissions: contents: write From 5570f265c69eb34068dc62dde9162eb665bc9e07 Mon Sep 17 00:00:00 2001 From: shimomo Date: Sun, 31 Aug 2025 14:19:39 +0900 Subject: [PATCH 3/3] ci: add composer dependency caching --- .github/workflows/cron.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/cron.yml b/.github/workflows/cron.yml index f372c18e..b4920207 100644 --- a/.github/workflows/cron.yml +++ b/.github/workflows/cron.yml @@ -28,6 +28,18 @@ jobs: with: fetch-depth: 0 + - name: Get Composer cache directory + id: composer-cache + run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT + + - name: Cache Composer dependencies + uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 + with: + path: ${{ steps.composer-cache.outputs.dir }} + key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }} + restore-keys: | + ${{ runner.os }}-php- + - name: Install base dependencies (without scraper) run: | composer remove bvp/scraper --no-update || true