Skip to content

Commit b7b45d7

Browse files
committed
trusted key
1 parent a43e192 commit b7b45d7

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

.github/workflows/publish.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,10 @@ jobs:
2424
# Only allow publishing from master branch
2525
# TODO: Remove publish-actin before merging
2626
if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/publish-actin'
27+
environment: release
2728
permissions:
2829
contents: write
30+
id-token: write
2931
steps:
3032
- uses: actions/checkout@v4
3133
with:
@@ -37,6 +39,9 @@ jobs:
3739
cache: 'npm'
3840
registry-url: 'https://registry.npmjs.org'
3941

42+
- name: Update npm for trusted publishing
43+
run: npm install -g npm@latest
44+
4045
- name: Install dependencies
4146
run: npm ci
4247

@@ -61,8 +66,6 @@ jobs:
6166
- name: Publish to npm
6267
if: ${{ inputs.dry_run == false }}
6368
run: npm publish --access public
64-
env:
65-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
6669

6770
- name: Create GitHub Release
6871
if: ${{ inputs.dry_run == false }}

0 commit comments

Comments
 (0)