diff --git a/.github/workflows/deploy-gh.yml b/.github/workflows/deploy-gh.yml index a14e7582..0ce5991e 100644 --- a/.github/workflows/deploy-gh.yml +++ b/.github/workflows/deploy-gh.yml @@ -72,21 +72,21 @@ jobs: id: cache-node-modules with: path: node_modules - key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package.json') }} + key: ${{ runner.os }}-modules-${{ hashFiles('**/package.json') }} - - name: Cache runs - uses: actions/cache@v4 - id: cache-runs + - name: Restore transformed runs + uses: actions/cache/restore@v4 + id: cache-runs-restore with: path: public/data/activities/transformed - key: ${{ runner.os }}-build-${{ env.cache-name }} + key: ${{ runner.os }}-runs - name: Cache auth uses: actions/cache@v4 id: cache-auth with: path: credentials.json - key: ${{ runner.os }}-build-${{ env.cache-name }} + key: ${{ runner.os }}-auth - name: Install run: npm install @@ -94,6 +94,13 @@ jobs: - name: Fetch runs run: node scripts/index + - name: Save transformed runs + uses: actions/cache/save@v4 + id: cache-runs-save + with: + path: public/data/activities/transformed + key: ${{ runner.os }}-runs + - name: Build runs list run: node scripts/list @@ -109,6 +116,22 @@ jobs: path: build retention-days: 1 + - name: Store runs data + if: ${{ !cancelled() }} + uses: actions/upload-artifact@v4 + with: + name: runs-data + path: public/data + retention-days: 1 + + - name: Store activity list + if: ${{ !cancelled() }} + uses: actions/upload-artifact@v4 + with: + name: activity-list + path: src/data/activity_list.json + retention-days: 1 + deploy: runs-on: ubuntu-latest needs: build