Skip to content

Commit 73bceac

Browse files
committed
Add cache action to cache dependencies
1 parent 74ce6e9 commit 73bceac

2 files changed

Lines changed: 12 additions & 0 deletions

File tree

.github/workflows/deploy.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,12 @@ jobs:
1919
node-version: '18'
2020
cache: 'yarn'
2121
registry-url: 'https://registry.npmjs.org'
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: Publish
2329
run: |
2430
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: Test TypeScript

0 commit comments

Comments
 (0)