From 67ba4caf03ce1c7cfdbd5822f9b57a0fceb2758e Mon Sep 17 00:00:00 2001 From: Oscar Dominguez Date: Mon, 5 Jul 2021 02:49:32 +0200 Subject: [PATCH] ci(workflow): add 'npm' cache for actions/setup-node in .github/workflows --- .github/workflows/ci.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5fc1086..94dcc53 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -4,7 +4,6 @@ on: [push] jobs: build: - runs-on: ubuntu-latest strategy: @@ -12,12 +11,13 @@ jobs: node-version: [8.x, 10.x, 12.x] steps: - - uses: actions/checkout@v1 - - name: Use Node.js ${{ matrix.node-version }} - uses: actions/setup-node@v1 - with: - node-version: ${{ matrix.node-version }} - - name: npm ci, and test - run: | - npm ci - npm test + - uses: actions/checkout@v1 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v2 + with: + node-version: ${{ matrix.node-version }} + cache: npm + - name: npm ci, and test + run: | + npm ci + npm test