Skip to content

Commit

Permalink
Merge pull request #7 from khmm12/infra/use-pnpm-cache
Browse files Browse the repository at this point in the history
infra: use pnpm cache in github action
  • Loading branch information
khmm12 authored Jun 20, 2024
2 parents b5f4add + 9596e0a commit 0e18a4d
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,16 @@ jobs:
with:
node-version: 20
cache: 'pnpm'

- name: Get pnpm store directory
id: pnpm-store-dir-path
run: echo "dir=$(pnpm store path --silent)" >> $GITHUB_OUTPUT
- name: Use pnpm cache
uses: actions/cache@v4
with:
path: ${{ steps.pnpm-store-dir-path.outputs.dir }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('pnpm-lock.yaml') }}
restore-keys: ${{ runner.os }}-pnpm-store-
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: ${{ matrix.step.name }}
Expand Down

0 comments on commit 0e18a4d

Please sign in to comment.