Skip to content

Commit

Permalink
ci: add a setup of pnpm setup and cache
Browse files Browse the repository at this point in the history
  • Loading branch information
sor4chi committed Sep 26, 2023
1 parent 3405d0b commit bea6c94
Showing 1 changed file with 20 additions and 2 deletions.
22 changes: 20 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,27 @@ jobs:
with:
node-version: 18.x

- uses: pnpm/action-setup@v2
name: Install pnpm
with:
version: 7
run_install: false

- name: Get pnpm store directory
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install Dependencies
run: pnpm install
run: pnpm install --frozen-lockfile

- name: Create Release Pull Request or Publish to npm
id: changesets
Expand All @@ -31,4 +50,3 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

0 comments on commit bea6c94

Please sign in to comment.