forked from mystiq/hydrogen-web
enable yarn cache, hopefully
This commit is contained in:
parent
b31dc38af1
commit
9de506d2a7
1 changed files with 16 additions and 5 deletions
21
.github/workflows/codechecks.js.yml
vendored
21
.github/workflows/codechecks.js.yml
vendored
|
@ -19,15 +19,26 @@ jobs:
|
|||
node-version: [14.x]
|
||||
|
||||
steps:
|
||||
- name: Checkout project source
|
||||
- name: Checkout source
|
||||
uses: actions/checkout@v2
|
||||
- name: Install tools
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: ${{ matrix.node-version }}
|
||||
- name: Install project dependencies
|
||||
run: npm install --also=dev
|
||||
# See: https://github.com/actions/cache/blob/main/examples.md#node---yarn
|
||||
- name: Get Yarn cache directory
|
||||
id: yarn-cache-dir-path
|
||||
run: echo "::set-output name=dir::$(yarn cache dir)"
|
||||
|
||||
- name: Use Yarn cache
|
||||
uses: actions/cache@v2
|
||||
id: yarn-cache
|
||||
with:
|
||||
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
|
||||
key: ${{ runner.os }}-yarn-${{ matrix.node-version }}-${{ hashFiles('**/yarn.lock') }}
|
||||
- name: Install dependencies
|
||||
run: yarn install --prefer-offline --frozen-lockfile
|
||||
- name: Unit tests
|
||||
run: npm test
|
||||
run: yarn test
|
||||
- name: Lint
|
||||
run: npm run lint-ci
|
||||
run: yarn run lint-ci
|
Loading…
Reference in a new issue