Skip to content

Commit 0690a9e

Browse files
committed
Add cache action to cache dependencies
1 parent 9bb6016 commit 0690a9e

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

.github/workflows/deploy.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@ jobs:
2222
node-version: '18'
2323
cache: 'yarn'
2424
registry-url: 'https://registry.npmjs.org'
25+
- name: Cache dependencies
26+
uses: actions/cache@v4
27+
with:
28+
path: |
29+
~/.cache
30+
key: dependencies-v1-${{ runner.os }}-${{ hashFiles('yarn.lock') }}
2531
- name: Publish
2632
run: |
2733
yarn install --frozen-lockfile --ignore-scripts --prefer-offline

.github/workflows/test.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,12 @@ jobs:
1919
with:
2020
node-version: '18'
2121
cache: 'yarn'
22+
- name: Cache dependencies
23+
uses: actions/cache@v4
24+
with:
25+
path: |
26+
~/.cache
27+
key: dependencies-v1-${{ runner.os }}-${{ hashFiles('yarn.lock') }}
2228
- name: Install
2329
run: yarn install --frozen-lockfile --ignore-scripts --prefer-offline
2430
- name: Linting files

0 commit comments

Comments
 (0)