Skip to content

Commit b36ef5b

Browse files
authored
chore: enable npm trusted publishing (#63)
Enable OIDC publishing to make it easier and more secure to publish npm packages from CI. - https://github.blog/changelog/2025-07-31-npm-trusted-publishing-with-oidc-is-generally-available/ - https://docs.npmjs.com/trusted-publishers
1 parent 959bac7 commit b36ef5b

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

.github/workflows/release.yml

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -16,28 +16,27 @@ permissions:
1616
jobs:
1717
publish:
1818
runs-on: ubuntu-latest
19+
environment: npm
1920
steps:
2021
- name: Checkout
2122
uses: actions/checkout@v4
2223

23-
- name: Install Pnpm
24-
run: npm i -g corepack@latest --force && corepack enable
25-
2624
- name: Setup Node.js
2725
uses: actions/setup-node@v4
2826
with:
2927
node-version: 22
30-
cache: "pnpm"
28+
29+
- name: Setup Package Managers
30+
run: |
31+
npm install -g npm@latest
32+
npm --version
33+
npm install -g corepack@latest --force
34+
corepack enable
3135
3236
- name: Install Dependencies
3337
run: pnpm install
3438

3539
- name: Publish
3640
uses: JS-DevTools/npm-publish@v3
3741
with:
38-
token: ${{ secrets.NPM_TOKEN }}
39-
40-
- name: Create GitHub Release
41-
uses: ncipollo/release-action@v1
42-
with:
43-
generateReleaseNotes: "true"
42+
token: empty

0 commit comments

Comments
 (0)