Use embedded cache utility of setup-node

This commit is contained in:
Matthieu MOREL
2022-02-25 11:37:43 +01:00
committed by GitHub
parent 3b89fff0ef
commit 0986cce16b
+3 -14
View File
@@ -11,24 +11,13 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-node@v3
with:
node-version: '16'
- name: Checkout
uses: actions/checkout@v2
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
- uses: actions/cache@v2
id: yarn-cache
- uses: actions/setup-node@v3
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
node-version: '16'
cache: yarn
- name: Build & Deploy
run: |