mirror of
https://github.com/actions/cache.git
synced 2025-03-14 04:07:00 +00:00
ci(workflow): add 'npm' cache for actions/setup-node in .github/workflows
This commit is contained in:
parent
5807af2642
commit
16f6b94fce
1 changed files with 85 additions and 85 deletions
10
.github/workflows/workflow.yml
vendored
10
.github/workflows/workflow.yml
vendored
|
@ -6,13 +6,13 @@ on:
|
||||||
- main
|
- main
|
||||||
- releases/**
|
- releases/**
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '**.md'
|
- "**.md"
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
- releases/**
|
- releases/**
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '**.md'
|
- "**.md"
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
# Build and unit test
|
# Build and unit test
|
||||||
|
@ -26,9 +26,10 @@ jobs:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
- name: Setup Node.js
|
- name: Setup Node.js
|
||||||
uses: actions/setup-node@v1
|
uses: actions/setup-node@v2
|
||||||
with:
|
with:
|
||||||
node-version: '12.x'
|
node-version: "12.x"
|
||||||
|
cache: npm
|
||||||
- name: Determine npm cache directory
|
- name: Determine npm cache directory
|
||||||
id: npm-cache
|
id: npm-cache
|
||||||
run: |
|
run: |
|
||||||
|
@ -58,7 +59,6 @@ jobs:
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
# End to end save and restore
|
# End to end save and restore
|
||||||
test-save:
|
test-save:
|
||||||
strategy:
|
strategy:
|
||||||
|
|
Loading…
Add table
Reference in a new issue