ci(workflow): add 'npm' cache for actions/setup-node in .github/workflows

This commit is contained in:
Oscar Dominguez
2021-07-18 22:34:12 +02:00
parent c0fad79083
commit bfafd34292

View File

@@ -3,20 +3,20 @@ on:
workflow_dispatch: workflow_dispatch:
inputs: inputs:
VERSION: VERSION:
description: 'Node.js version to build and upload' description: "Node.js version to build and upload"
required: true required: true
default: '14.2.0' default: "14.2.0"
PUBLISH_RELEASES: PUBLISH_RELEASES:
description: 'Whether to publish releases' description: "Whether to publish releases"
required: true required: true
default: 'false' default: "false"
pull_request: pull_request:
paths-ignore: paths-ignore:
- 'versions-manifest.json' - "versions-manifest.json"
- 'LICENSE' - "LICENSE"
- '**.md' - "**.md"
branches: branches:
- 'main' - "main"
env: env:
VERSION: ${{ github.event.inputs.VERSION || '14.0.0' }} VERSION: ${{ github.event.inputs.VERSION || '14.0.0' }}
@@ -99,6 +99,7 @@ jobs:
uses: actions/setup-node@v2.1.2 uses: actions/setup-node@v2.1.2
with: with:
node-version: ${{ env.VERSION }} node-version: ${{ env.VERSION }}
cache: npm
- name: Wait for the logs - name: Wait for the logs
run: | run: |