Skip to content

Commit 4b90245

Browse files
authored
ci(workflow): add 'npm' cache for actions/setup-node in .github/workflows (#388)
1 parent 849f602 commit 4b90245

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

.github/workflows/release.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@ jobs:
1414
steps:
1515
- uses: actions/checkout@v2
1616
- uses: actions/setup-node@v2
17-
- uses: bahmutov/npm-install@v1
17+
with:
18+
cache: npm
19+
- run: npm ci
1820
- run: npx semantic-release
1921
env:
2022
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/test.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ jobs:
2525
uses: actions/setup-node@v2
2626
with:
2727
node-version: "${{ matrix.node-version }}"
28-
- uses: bahmutov/npm-install@v1
28+
cache: npm
29+
- run: npm ci
2930
- run: "npm run test:ci"
3031
test:
3132
runs-on: ubuntu-latest
@@ -36,6 +37,7 @@ jobs:
3637
uses: actions/setup-node@v2
3738
with:
3839
node-version: "${{ matrix.node-version }}"
39-
- uses: bahmutov/npm-install@v1
40+
cache: npm
41+
- run: npm ci
4042
- run: npm run lint
4143
- run: npx lockfile-lint --path package-lock.json

0 commit comments

Comments
 (0)