Skip to content

Commit 9de8ff5

Browse files
fix(ci): add build step before publish + pass NPM_TOKEN as NODE_AUTH_TOKEN (#49)
Two fixes for the release workflow: 1. Add 'pnpm build' step before changesets publish — dist/ must exist for npm publish (CLI bin was missing: 'No bin file found at dist/index.js') 2. Pass NPM_TOKEN as NODE_AUTH_TOKEN env var to the changesets action — npm reads NODE_AUTH_TOKEN for registry auth, not NPM_TOKEN
1 parent 5e0f7bb commit 9de8ff5

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

‎.github/workflows/release.yml‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ jobs:
3838
- name: Install dependencies
3939
run: pnpm install --frozen-lockfile
4040

41+
- name: Build packages
42+
run: pnpm build
43+
4144
- name: Create release PR or publish
4245
id: changesets
4346
uses: changesets/action@v1.9.0
@@ -49,6 +52,7 @@ jobs:
4952
env:
5053
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5154
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
55+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
5256

5357
- name: Create ecosystem tag and GitHub release
5458
if: steps.changesets.outputs.published == 'true'

0 commit comments

Comments
 (0)