From 5607f4593cf5c9c101ded8edb29798b719b73012 Mon Sep 17 00:00:00 2001 From: Ventsislav Kostadinov Date: Sat, 26 Sep 2026 13:43:23 +0300 Subject: [PATCH] ci: publish from the npm environment The npm environment only allows deployments from main, so the OIDC token for trusted publishing can only be minted for main. --- .github/workflows/release.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index d313252..f30dd5b 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -63,6 +63,9 @@ jobs: runs-on: ubuntu-latest needs: [release-please] if: needs.release-please.outputs.release_created == 'true' + # Environment `npm` only allows deployments from `main`. The npm trusted + # publisher's "Environment name" must be `npm` too (OIDC sub changes). + environment: npm permissions: contents: read id-token: write