From 5258316c4f169abb1b2714d9db81631414528e31 Mon Sep 17 00:00:00 2001 From: Nate Moore Date: Mon, 13 Dec 2021 13:55:35 -0600 Subject: [PATCH] Update `turbo` cache (#2184) * chore(actions): update cache strategy * chore: force ci --- .github/workflows/ci.yml | 33 ++++++++++++++++++++------------- 1 file changed, 20 insertions(+), 13 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 0bb48fb96..15df0d839 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -83,11 +83,15 @@ jobs: node-version: 16 cache: 'yarn' - - name: Cache Turbo + - name: Cache Node Modules + id: cache-node uses: actions/cache@v2 with: - path: "**/.turbo" - key: turbo-${{ hashFiles('.github/workflows/ci.yml') }}-${{ github.ref }} + path: "**/node_modules" + key: cache-node_modules-${{ hashFiles('**/yarn.lock') }}-${{ github.run_id }} + restore-keys: | + cache-node_modules-${{ hashFiles('**/yarn.lock') }}-${{ github.run_id }} + cache-node_modules-${{ hashFiles('**/yarn.lock') }}- - name: Install NPM Dependencies run: yarn install --prefer-offline --frozen-lockfile --ignore-engines --registry https://registry.npmjs.org --network-timeout 300000 @@ -95,7 +99,7 @@ jobs: CI: true - name: Build Packages - run: yarn build + run: yarn build --force - name: Upload Package Artifacts uses: actions/upload-artifact@v2 @@ -137,11 +141,12 @@ jobs: - name: Extract Artifacts run: ./.github/extract-artifacts.sh - - name: Cache Turbo + - name: Cache Node Modules + id: cache-node uses: actions/cache@v2 with: - path: "**/.turbo" - key: turbo-${{ hashFiles('.github/workflows/ci.yml') }}-${{ github.ref }} + path: "**/node_modules" + key: cache-node_modules-${{ hashFiles('**/yarn.lock') }}-${{ github.run_id }} - name: Install NPM Dependencies run: yarn install --prefer-offline --frozen-lockfile --ignore-engines --registry https://registry.npmjs.org --network-timeout 300000 @@ -181,11 +186,12 @@ jobs: - name: Extract Artifacts run: ./.github/extract-artifacts.sh - - name: Cache Turbo + - name: Cache Node Modules + id: cache-node uses: actions/cache@v2 with: - path: "**/.turbo" - key: turbo-${{ hashFiles('.github/workflows/ci.yml') }}-${{ github.ref }} + path: "**/node_modules" + key: cache-node_modules-${{ hashFiles('**/yarn.lock') }}-${{ github.run_id }} - name: Install NPM Dependencies run: yarn install --prefer-offline --frozen-lockfile --ignore-engines --registry https://registry.npmjs.org --network-timeout 300000 @@ -220,11 +226,12 @@ jobs: - name: Extract Artifacts run: ./.github/extract-artifacts.sh - - name: Cache Turbo + - name: Cache Node Modules + id: cache-node uses: actions/cache@v2 with: - path: "**/.turbo" - key: turbo-${{ hashFiles('.github/workflows/ci.yml') }}-${{ github.ref }} + path: "**/node_modules" + key: cache-node_modules-${{ hashFiles('**/yarn.lock') }}-${{ github.run_id }} - name: Install NPM Dependencies run: yarn install --prefer-offline --frozen-lockfile --ignore-engines --registry https://registry.npmjs.org --network-timeout 300000