Skip to content

Commit

Permalink
Merge pull request #249 from gopasspw/fix-checks
Browse files Browse the repository at this point in the history
Simplify and fix CI caching
  • Loading branch information
Pharb authored Sep 8, 2024
2 parents 9d7dc4d + 6fa072a commit 072eb24
Showing 1 changed file with 3 additions and 15 deletions.
18 changes: 3 additions & 15 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 All @@ -49,6 +36,7 @@ jobs:

- name: Upload coverage to Codecov
# Docs: https://github.com/marketplace/actions/codecov
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}

0 comments on commit 072eb24

Please sign in to comment.