Skip to content

Commit 69e9b45

Browse files
committed
ci: migrate to new npm publish infra
1 parent 630b8cc commit 69e9b45

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

.github/workflows/npm-publish.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,24 @@
1-
# When anyone pushes to npm branch in this repo, the package will be published to npm. This action requires
2-
# access to NPM_TOKEN secret. Contact core.ai admins to get access to core.ais org tokens.
3-
# To publish to your own npm account, follow this https://docs.npmjs.com/creating-and-viewing-access-tokens
1+
# When anyone pushes to npm branch in this repo, the package will be published to npm.
2+
# https://docs.npmjs.com/trusted-publishers is active in this repo
43
name: Publish package to npm
54

65
on:
76
push:
87
branches: [ npm ]
98

9+
permissions:
10+
id-token: write # Required for OIDC
11+
contents: read
12+
1013
jobs:
1114
build-tasks:
1215
runs-on: ubuntu-latest
1316
steps:
14-
- uses: actions/checkout@v4
17+
- uses: actions/checkout@v6
18+
- uses: actions/setup-node@v4
19+
with:
20+
node-version: '24'
21+
registry-url: 'https://registry.npmjs.org'
1522
- name: Npm Install
1623
run: |
1724
npm ci
@@ -22,5 +29,3 @@ jobs:
2229
- name: Publishing package to npm repository
2330
run: |
2431
npm publish --access public
25-
env:
26-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)