Skip to content

Commit bc184bf

Browse files
author
Tanjeem Hossain
committed
ci: modify pre-release to use OIDC
Ticket: DX-2083
1 parent 837b8ee commit bc184bf

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

.github/workflows/prerelease.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,11 @@
11
name: Prerelease
2+
permissions:
3+
# Needed for npm Trusted Publishing
4+
id-token: write
5+
# Needed for semantic-release
6+
contents: write
7+
pull-requests: write
8+
issues: write
29
on:
310
push:
411
branches:
@@ -7,6 +14,7 @@ jobs:
714
release:
815
name: Prerelease
916
runs-on: ubuntu-latest
17+
environment: publish
1018
steps:
1119
- name: Checkout
1220
uses: actions/checkout@v4
@@ -15,14 +23,13 @@ jobs:
1523
- name: Setup Node.js
1624
uses: actions/setup-node@v4
1725
with:
18-
node-version: 20.x
26+
node-version: 22.x
1927
- name: Install dependencies
2028
run: yarn
2129
- name: Build library
2230
run: yarn build:prod
2331
- name: Release
2432
env:
2533
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
26-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
2734
BRANCH_NAME: ${{ github.head_ref || github.ref_name }}
2835
run: yarn run semantic-release

0 commit comments

Comments
 (0)