Skip to content

Commit dde9cc1

Browse files
committed
Update release.yml for trusted publishing to npmjs.com.
1 parent c9a66c9 commit dde9cc1

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

.github/workflows/release.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ on:
66

77
name: Create Release
88

9+
permissions:
10+
id-token: write # Required for OIDC
11+
contents: read
12+
913
jobs:
1014
build:
1115
name: Create Release
@@ -22,10 +26,7 @@ jobs:
2226
- run: npm run build
2327
- name: Publish to NPM
2428
run: |
25-
npm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN}
2629
npm publish --ignore-scripts --access public
27-
env:
28-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
2930
- name: Create artifact
3031
run: |
3132
mkdir ${{ env.RELEASE_VERSION }}-dist && cp dist/farmOS-map* ${{ env.RELEASE_VERSION }}-dist && zip -r ${{ env.RELEASE_VERSION }}-dist.zip ${{ env.RELEASE_VERSION }}-dist

0 commit comments

Comments
 (0)