Skip to content

Commit

Permalink
chore: invalidate cache in github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
adamviktora committed Oct 8, 2024
1 parent 06b4eff commit 1945a22
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
18 changes: 9 additions & 9 deletions .github/workflows/build-lint-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
packages/*/package.json
packages/*/patternfly-docs/content/**
packages/*/patternfly-docs/generated/**
key: ${{ runner.os }}-setup-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('package.json', 'packages/module/package.json') }}
key: ${{ runner.os }}-setup-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('package.json', 'packages/module/package.json') }}
- uses: actions/setup-node@v4
with:
node-version: '20'
Expand All @@ -39,13 +39,13 @@ jobs:
path: |
node_modules
**/node_modules
key: ${{ runner.os }}-yarn-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-yarn-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
- uses: actions/cache@v4
id: lint-cache
name: Load lint cache
with:
path: '.eslintcache'
key: ${{ runner.os }}-lint-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-lint-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
- name: ESLint
run: yarn lint:js
- name: MDLint
Expand Down Expand Up @@ -75,7 +75,7 @@ jobs:
packages/*/package.json
packages/*/patternfly-docs/content/**
packages/*/patternfly-docs/generated/**
key: ${{ runner.os }}-setup-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('package.json', 'packages/module/package.json') }}
key: ${{ runner.os }}-setup-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('package.json', 'packages/module/package.json') }}
- uses: actions/setup-node@v4
with:
node-version: '20'
Expand All @@ -87,7 +87,7 @@ jobs:
node_modules
**/node_modules
~/.cache/Cypress
key: ${{ runner.os }}-yarn-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-yarn-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
- run: yarn install --frozen-lockfile
if: steps.yarn-cache.outputs.cache-hit != 'true'
- uses: actions/cache@v4
Expand All @@ -97,7 +97,7 @@ jobs:
path: |
packages/*/dist
packages/react-styles/css
key: ${{ runner.os }}-dist-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock', 'package.json', 'packages/*/*', '!packages/*/dist', '!packages/*/node_modules') }}
key: ${{ runner.os }}-dist-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock', 'package.json', 'packages/*/*', '!packages/*/dist', '!packages/*/node_modules') }}
- name: Build dist
run: yarn build
if: steps.dist.outputs.cache-hit != 'true'
Expand Down Expand Up @@ -128,7 +128,7 @@ jobs:
packages/*/package.json
packages/*/patternfly-docs/content/**
packages/*/patternfly-docs/generated/**
key: ${{ runner.os }}-setup-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('package.json', 'packages/module/package.json') }}
key: ${{ runner.os }}-setup-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('package.json', 'packages/module/package.json') }}
- uses: actions/setup-node@v4
with:
node-version: '20'
Expand All @@ -140,7 +140,7 @@ jobs:
node_modules
**/node_modules
~/.cache/Cypress
key: ${{ runner.os }}-yarn-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-yarn-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
- run: yarn install --frozen-lockfile
if: steps.yarn-cache.outputs.cache-hit != 'true'
- uses: actions/cache@v4
Expand All @@ -150,7 +150,7 @@ jobs:
path: |
packages/*/dist
packages/react-styles/css
key: ${{ runner.os }}-dist-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock', 'package.json', 'packages/*/*', '!packages/*/dist', '!packages/*/node_modules') }}
key: ${{ runner.os }}-dist-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock', 'package.json', 'packages/*/*', '!packages/*/dist', '!packages/*/node_modules') }}
- name: Build dist
run: yarn build
if: steps.dist.outputs.cache-hit != 'true'
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
packages/*/package.json
packages/*/patternfly-docs/content/**
packages/*/patternfly-docs/generated/**
key: ${{ runner.os }}-setup-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('package.json', 'packages/module/package.json') }}
key: ${{ runner.os }}-setup-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('package.json', 'packages/module/package.json') }}
- name: Run build script
run: ./devSetup.sh
shell: bash
Expand All @@ -40,7 +40,7 @@ jobs:
path: |
node_modules
**/node_modules
key: ${{ runner.os }}-yarn-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-yarn-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
- run: yarn install --frozen-lockfile
if: steps.yarn-cache.outputs.cache-hit != 'true'
- uses: actions/cache@v4
Expand All @@ -49,7 +49,7 @@ jobs:
with:
path: |
packages/*/dist
key: ${{ runner.os }}-dist-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock', 'package.json', 'packages/*/*', '!packages/*/dist', '!packages/*/node_modules') }}
key: ${{ runner.os }}-dist-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock', 'package.json', 'packages/*/*', '!packages/*/dist', '!packages/*/node_modules') }}
- name: Build dist
run: yarn build
if: steps.dist.outputs.cache-hit != 'true'
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
node_modules
**/node_modules
~/.cache/Cypress
key: ${{ runner.os }}-yarn-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-yarn-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock') }}
- run: yarn install --frozen-lockfile
if: steps.yarn-cache.outputs.cache-hit != 'true'
- uses: actions/cache@v4
Expand All @@ -38,7 +38,7 @@ jobs:
path: |
packages/*/dist
packages/react-styles/css
key: ${{ runner.os }}-dist-14-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock', 'package.json', 'packages/*/*', '!packages/*/dist', '!packages/*/node_modules') }}
key: ${{ runner.os }}-dist-15-${{ secrets.CACHE_VERSION }}-${{ hashFiles('yarn.lock', 'package.json', 'packages/*/*', '!packages/*/dist', '!packages/*/node_modules') }}
- name: Build dist
run: yarn build
if: steps.dist.outputs.cache-hit != 'true'
Expand Down

0 comments on commit 1945a22

Please sign in to comment.