Skip to content

Commit c92c7de

Browse files
authored
ci(action): add deps cache support based on package.json (#145)
* ci: add ci cache support * ci: make ci cache based on package.json * ci: rename path * chore: remove useless env files
1 parent e6b76ce commit c92c7de

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

.github/workflows/build.yml

+11-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,17 @@ jobs:
1616
with:
1717
node-version: '12'
1818

19-
- name: ci
19+
- name: Cache node modules
20+
uses: actions/cache@v2
21+
env:
22+
cache-name: cache-node-modules
23+
with:
24+
path: ./node_modules
25+
key: ${{ runner.os }}-build-cache-node-modules-${{ hashFiles('**/package.json') }}
26+
restore-keys: |
27+
cache-node-modules-
28+
29+
- name: Run ci
2030
run: |
2131
npm install
2232
npm run ci

0 commit comments

Comments
 (0)