From 27ee09f5926cb03d892d4b3d7a5f0775177ba809 Mon Sep 17 00:00:00 2001 From: Matthias Kretschmann Date: Tue, 25 May 2021 14:08:48 +0200 Subject: [PATCH] GitHub Actions caching tweak --- .github/workflows/ci.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 02078ab0..f1902cd7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,16 +16,18 @@ jobs: - uses: actions/checkout@v2 - name: Setup Node.js - uses: actions/setup-node@v1 + uses: actions/setup-node@v2 with: node-version: '14' - name: Cache node modules - uses: actions/cache@v1 + uses: actions/cache@v2 + env: + cache-name: cache-node-modules with: path: ~/.npm - key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} - restore-keys: ${{ runner.os }}-node- + key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} + restore-keys: ${{ runner.os }}-build-${{ env.cache-name }}- - run: npm ci - run: npm test