From c43b1ac86e10d7c97029be6f8980aac40bf0f6e5 Mon Sep 17 00:00:00 2001 From: Ivan Shumkov Date: Tue, 23 Dec 2025 18:23:47 +0700 Subject: [PATCH 1/2] ci: fix NPM publish in release --- .github/actions/nodejs/action.yaml | 8 +++++++- .github/workflows/release.yml | 11 +++++++++-- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/.github/actions/nodejs/action.yaml b/.github/actions/nodejs/action.yaml index 8460a19d168..4141c5fe6d9 100644 --- a/.github/actions/nodejs/action.yaml +++ b/.github/actions/nodejs/action.yaml @@ -1,13 +1,19 @@ --- name: "Setup Node.JS" description: "Setup Node.JS binaries, dependencies and cache" +inputs: + node-version: + description: "Node.js version to use" + required: false + default: "20" runs: using: composite steps: - name: Setup Node.JS uses: actions/setup-node@v4 with: - node-version: "20" + node-version: ${{ inputs.node-version }} + registry-url: "https://registry.npmjs.org" - name: Enable corepack shell: bash diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e9f3992c6b9..a5bf3278bd6 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -18,6 +18,11 @@ concurrency: group: ${{ github.workflow }}-${{ github.ref }} cancel-in-progress: true +# Required for NPM publish +permissions: + id-token: write + contents: read + jobs: release-npm: name: Release NPM packages @@ -120,8 +125,10 @@ jobs: echo "NPM suffix: ${{ steps.suffix.outputs.result }}" echo "NPM release tag: ${{ steps.tag.outputs.result }}" - - name: Configure NPM auth token - run: yarn config set npmAuthToken ${{ secrets.NPM_TOKEN }} + - name: Setup Node.JS + uses: ./.github/actions/nodejs + with: + node-version: 24 - name: Publish NPM packages run: yarn workspaces foreach --all --no-private --parallel npm publish --tolerate-republish --access public --tag ${{ steps.tag.outputs.result }} From d4ec3f22673286382ac4d85e40f49ccd9d885f69 Mon Sep 17 00:00:00 2001 From: Ivan Shumkov Date: Tue, 23 Dec 2025 18:31:09 +0700 Subject: [PATCH 2/2] docs: add comment --- .github/workflows/release.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a5bf3278bd6..f73d9154d55 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -125,6 +125,7 @@ jobs: echo "NPM suffix: ${{ steps.suffix.outputs.result }}" echo "NPM release tag: ${{ steps.tag.outputs.result }}" + # We need NodeJS 24 for https://docs.npmjs.com/trusted-publishers - name: Setup Node.JS uses: ./.github/actions/nodejs with: