Skip to content

Commit b0500ed

Browse files
authored
ci(publish): use tool versions for Node release runtime (#199)
Configure the JavaScript publish workflow to read Node from .tool-versions and add the same Node, npm, and pnpm tool versions used by the working braintrust-sdk-javascript publish flow. The previous rerun cleared npm token environment variables correctly, but the GitHub runner's Node 22 image used npm 10.9.8 and failed trusted publishing with ENEEDAUTH. Moving the publish workflow to Node 24 gives it npm 11 support for GitHub OIDC trusted publishing without a one-off npm install step.
1 parent 8eb18c2 commit b0500ed

2 files changed

Lines changed: 5 additions & 2 deletions

File tree

.github/workflows/publish-js.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
- name: Set up Node.js
4747
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
4848
with:
49-
node-version: 22
49+
node-version-file: .tool-versions
5050
- name: Determine release metadata
5151
id: release_metadata
5252
env:
@@ -110,7 +110,7 @@ jobs:
110110
- name: Set up Node.js
111111
uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
112112
with:
113-
node-version: 22
113+
node-version-file: .tool-versions
114114
registry-url: https://registry.npmjs.org
115115

116116
- uses: pnpm/action-setup@fc06bc1257f339d1d5d8b3a19a8cae5388b55320 # v5.0.0

.tool-versions

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,4 @@
11
python 3.13.5
2+
nodejs 24.15.0
3+
npm 11.12.1
4+
pnpm 10.33.0

0 commit comments

Comments
 (0)