Skip to content

Commit 9e3940b

Browse files
chore: Update publish workflow to use trusted publishing
1 parent c9d4d63 commit 9e3940b

File tree

1 file changed

+7
-10
lines changed

1 file changed

+7
-10
lines changed

.github/workflows/publish_to_npm.yml

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,21 @@ on:
33
release:
44
types: [published]
55
workflow_dispatch:
6-
6+
7+
permissions:
8+
contents: read
9+
id-token: write
10+
711
jobs:
8-
build:
12+
publish:
913
runs-on: ubuntu-latest
10-
permissions:
11-
contents: read
12-
id-token: write
1314
steps:
1415
- uses: actions/checkout@v4
15-
# Setup .npmrc file to publish to npm
1616
- uses: actions/setup-node@v4
1717
with:
1818
node-version: '22.x'
1919
registry-url: 'https://registry.npmjs.org'
20-
# Install dependencies without modifying package-lock.json file
20+
# Install dependencies without modifying package-lock.json file
2121
- run: npm install --no-save
2222
- run: npm run build
2323
- run: lerna publish from-package --yes
24-
env:
25-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
26-
NPM_CONFIG_PROVENANCE: true

0 commit comments

Comments
 (0)