mirror of
https://github.com/anuraghazra/github-readme-stats.git
synced 2025-01-24 13:59:08 +08:00
ci(workflow): add 'npm' cache for actions/setup-node in .github/workflows (#1382)
This commit is contained in:
parent
02ebd3243b
commit
2723f00cb8
3
.github/workflows/generate-theme-doc.yml
vendored
3
.github/workflows/generate-theme-doc.yml
vendored
@ -14,9 +14,10 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: setup node
|
||||
uses: actions/setup-node@v1
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: "12.x"
|
||||
cache: npm
|
||||
|
||||
- name: npm install, generate readme
|
||||
run: |
|
||||
|
14
.github/workflows/test.yml
vendored
14
.github/workflows/test.yml
vendored
@ -16,20 +16,10 @@ jobs:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- name: Setup Node
|
||||
uses: actions/setup-node@v1
|
||||
uses: actions/setup-node@v2
|
||||
with:
|
||||
node-version: "12.x"
|
||||
|
||||
- name: Cache node modules
|
||||
uses: actions/cache@v2
|
||||
env:
|
||||
cache-name: cache-node-modules
|
||||
with:
|
||||
path: ~/.npm
|
||||
key:
|
||||
${{ runner.os }}-npm-cache-${{ hashFiles('**/package-lock.json') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-npm-cache-
|
||||
cache: npm
|
||||
|
||||
- name: Install & Test
|
||||
run: |
|
||||
|
Loading…
Reference in New Issue
Block a user