From 9ca0cb2a68b2ea90fbcc3feb4bae130b9f627c75 Mon Sep 17 00:00:00 2001 From: Nick Schonning Date: Tue, 7 Dec 2021 15:05:31 -0500 Subject: [PATCH] chore: use NPM cache in setup-node --- .github/workflows/nodejs.yml | 5 +++-- .github/workflows/publish.yml | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/nodejs.yml b/.github/workflows/nodejs.yml index 7959e887..e87c38ca 100644 --- a/.github/workflows/nodejs.yml +++ b/.github/workflows/nodejs.yml @@ -6,7 +6,7 @@ jobs: build: runs-on: ubuntu-latest - + strategy: matrix: node-version: [12.x, 14.x, 16.x] @@ -14,9 +14,10 @@ jobs: steps: - uses: actions/checkout@v1 - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 + uses: actions/setup-node@v2 with: node-version: ${{ matrix.node-version }} + cache: npm - name: npm install, build, and test run: | npm ci diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 732c6a4a..e35b09c4 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -13,6 +13,7 @@ jobs: with: node-version: 14 registry-url: https://registry.npmjs.org/ + cache: npm - run: npm ci - run: npm run build --if-present - run: npm test