Skip to content

Commit d2bf1b9

Browse files
shannahclaude
andauthored
fix: update Node to 20.x and upgrade npm for trusted publishing support (#455)
Node 16 ships with npm 8.x which doesn't support npm trusted publishing (OIDC provenance), requiring npm 9.5+. This updates the GitHub Action to use actions/setup-node@v4 with Node 20.x and adds an npm upgrade step, matching the pattern already used in .github/workflows/maven.yml. https://claude.ai/code/session_013qz1NYPTSvpAWsjdDXZqLk Co-authored-by: Claude <noreply@anthropic.com>
1 parent 5c77363 commit d2bf1b9

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

‎action.yml‎

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,11 +117,16 @@ runs:
117117
git config user.email "<>"
118118
- name: Set up Node
119119
if: ${{ env.JDEPLOY_SKIP_EXECUTION != 'true' }}
120-
uses: actions/setup-node@v2
120+
uses: actions/setup-node@v4
121121
with:
122-
node-version: '16.x'
122+
node-version: '20.x'
123123
registry-url: 'https://registry.npmjs.org'
124124

125+
- name: Upgrade npm for trusted publishing
126+
if: ${{ env.JDEPLOY_SKIP_EXECUTION != 'true' }}
127+
run: npm install -g npm@latest
128+
shell: bash
129+
125130
- name: Setup jDeploy Registry
126131
if: ${{ env.JDEPLOY_SKIP_EXECUTION != 'true' }}
127132
shell: bash

0 commit comments

Comments
 (0)