Skip to content

Commit e0dd4ea

Browse files
updated release workflow
1 parent 616d4d5 commit e0dd4ea

1 file changed

Lines changed: 4 additions & 19 deletions

File tree

.github/workflows/release.yml

Lines changed: 4 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
name: Release (main)
2+
13
on:
24
push:
35
branches:
@@ -6,12 +8,9 @@ on:
68
jobs:
79
build-test-release:
810
runs-on: ubuntu-latest
9-
env:
10-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} # make token available to all steps
1111
permissions:
1212
contents: read
1313
id-token: write # CRITICAL: This enables OIDC authentication
14-
packages: write
1514

1615
steps:
1716
- name: Checkout
@@ -39,21 +38,7 @@ jobs:
3938
- name: Build library
4039
run: npm run build
4140

42-
- name: Configure npm auth (for verification steps)
43-
run: |
44-
# write auth token into the runner userconfig so npm CLI will use it
45-
# we avoid printing the token; GitHub masks secrets automatically
46-
npm config set //registry.npmjs.org/:_authToken "${NODE_AUTH_TOKEN}" --userconfig /home/runner/work/_temp/.npmrc || true
47-
48-
- name: Verify npm auth + dry run
49-
run: |
50-
echo "whoami:"
51-
npm whoami --registry=https://registry.npmjs.org || true
52-
echo "--- npm config (userconfig) ---"
53-
npm config list --userconfig /home/runner/work/_temp/.npmrc || true
54-
echo "--- dry-run publish (will NOT publish) ---"
55-
cd dist/ngbootstrap && npm publish --access public --dry-run || true
56-
5741
- name: Publish to npm
42+
# OIDC handles authentication automatically now.
5843
working-directory: dist/ngbootstrap
59-
run: npm publish --provenance --access public
44+
run: npm publish --provenance --access public # publish the built package only

0 commit comments

Comments
 (0)