Skip to content
This repository was archived by the owner on Jul 9, 2024. It is now read-only.

Commit 6cf8d0f

Browse files
committed
ci: use cache feature of @actions/setup-node
1 parent 2edde93 commit 6cf8d0f

1 file changed

Lines changed: 5 additions & 20 deletions

File tree

.github/workflows/test-and-release.yaml

Lines changed: 5 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -57,12 +57,7 @@ jobs:
5757
- uses: actions/setup-node@v4
5858
with:
5959
node-version: "20.x"
60-
61-
- name: Keep npm cache around to speed up installs
62-
uses: actions/cache@v4
63-
with:
64-
path: ~/.npm
65-
key: ${{ runner.OS }}-build-${{ hashFiles('**/package-lock.json') }}
60+
cache: "npm"
6661

6762
- name: Install dependencies
6863
run: npm ci --no-audit
@@ -130,7 +125,7 @@ jobs:
130125
- uses: actions/setup-node@v4
131126
with:
132127
node-version: "20.x"
133-
128+
cache: "npm"
134129
- name: Create resource group
135130
id: resource-group
136131
run: |
@@ -178,7 +173,7 @@ jobs:
178173
- uses: actions/setup-node@v4
179174
with:
180175
node-version: "20.x"
181-
176+
cache: "npm"
182177
- name: Create integration resources
183178
id: resources
184179
run: |
@@ -255,12 +250,7 @@ jobs:
255250
- uses: actions/setup-node@v4
256251
with:
257252
node-version: "20.x"
258-
259-
- name: Keep npm cache around to speed up installs
260-
uses: actions/cache@v4
261-
with:
262-
path: ~/.npm
263-
key: ${{ runner.OS }}-build-${{ hashFiles('**/package-lock.json') }}
253+
cache: "npm"
264254

265255
- name: Install dependencies
266256
run: npm ci --no-audit
@@ -359,12 +349,7 @@ jobs:
359349
- uses: actions/setup-node@v4
360350
with:
361351
node-version: "20.x"
362-
363-
- name: Keep npm cache around to speed up installs
364-
uses: actions/cache@v4
365-
with:
366-
path: ~/.npm
367-
key: build-${{ hashFiles('**/package-lock.json') }}
352+
cache: "npm"
368353

369354
- name: Install dependencies
370355
run: npm ci --no-audit

0 commit comments

Comments
 (0)