Skip to content

Commit

Permalink
CI: use custom (better) Yarn cache strategy
Browse files Browse the repository at this point in the history
  • Loading branch information
mrtnzlml authored and kodiakhq[bot] committed Jul 15, 2022
1 parent 0b0089a commit 82d9052
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion .github/workflows/continuous-integration-javascript.yml
Expand Up @@ -29,7 +29,19 @@ jobs:
uses: actions/setup-node@v3.4.1
with:
node-version: ${{ matrix.node-version }}
cache: 'yarn'

- name: Get Yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"

# https://github.com/actions/cache
- name: Restore Yarn cache
uses: actions/cache@v3.0.5
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: yarn-cache-folder-${{ hashFiles('**/yarn.lock', '.yarnrc.yml') }}
restore-keys: |
yarn-cache-folder-
- name: Install Yarn dependencies
run: yarn install --immutable
Expand Down

0 comments on commit 82d9052

Please sign in to comment.