Skip to content

Commit

Permalink
Try pnpm again
Browse files Browse the repository at this point in the history
  • Loading branch information
davidkpiano committed Aug 2, 2024
1 parent 1c6022a commit e4578ae
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 21 deletions.
22 changes: 11 additions & 11 deletions .github/actions/ci-setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,18 @@ runs:
- uses: actions/setup-node@v4
with:
node-version: 20.x

- name: install pnpm
run: npm i pnpm@latest -g
shell: bash

- name: Get pnpm store directory
- name: Setup npmrc
run: echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > .npmrc
shell: bash
id: pnpm-cache
run: |
echo "pnpm_cache_dir=$(pnpm store path | tr -d '\n')" >> $GITHUB_OUTPUT
- uses: actions/cache@v4
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-

- name: setup pnpm config
run: pnpm config set store-dir $PNPM_CACHE_FOLDER
shell: bash

- run: pnpm install
shell: bash
12 changes: 2 additions & 10 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,11 @@ jobs:
- uses: actions/checkout@v4
- uses: ./.github/actions/ci-setup

- name: Setup Node.js 20.x
uses: actions/setup-node@v4
with:
node-version: 20.x

- name: Install dependencies
run: npm install

- name: Create Release Pull Request or Publish to npm
uses: changesets/action@v1
with:
publish: npm run release
version: npm run version
publish: pnpm run release
version: pnpm run version
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

0 comments on commit e4578ae

Please sign in to comment.