Skip to content

Commit

Permalink
Simplify and fix CI caching
Browse files Browse the repository at this point in the history
  • Loading branch information
Pharb committed Sep 8, 2024
1 parent 9d7dc4d commit ea35c85
Showing 1 changed file with 1 addition and 14 deletions.
15 changes: 1 addition & 14 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,7 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}

- name: Get yarn cache directory path
# Docs: https://github.com/actions/cache/blob/master/examples.md#node---yarn
id: yarn-cache-dir-path
run: echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT

- uses: actions/cache@v4
# Docs: https://github.com/actions/cache/blob/master/examples.md#node---yarn
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
cache: yarn

- run: yarn --frozen-lockfile --non-interactive --no-progress --check-files

Expand Down

0 comments on commit ea35c85

Please sign in to comment.