Skip to content

fix(ci): use intervene-ci PAT for semantic-release#99

Merged
pablofmena merged 1 commit intomasterfrom
pablomena/fix/release-ci-token-asahf
Apr 6, 2026
Merged

fix(ci): use intervene-ci PAT for semantic-release#99
pablofmena merged 1 commit intomasterfrom
pablomena/fix/release-ci-token-asahf

Conversation

@pablofmena
Copy link
Copy Markdown
Contributor

Scope

Follow-up to #96 and #98. The GITHUB_TOKEN cannot push to protected branches — this is a GitHub platform limitation regardless of push restriction settings. Switches back to CI_TOKEN (a fine-grained PAT from intervene-ci, which is in the master push restrictions) for semantic-release operations.

Implementation

  • GH_TOKEN set to CI_TOKEN secret — used by semantic-release for both GitHub API calls (@semantic-release/github) and git push (@semantic-release/git).
  • persist-credentials: false restored on checkout — prevents actions/checkout from injecting GITHUB_TOKEN git credentials that would conflict with the PAT.
  • id-token: write kept for npm OIDC provenance publishing.
  • contents: write and issues: write removed from workflow permissions — no longer needed since the PAT provides those scopes.
  • CI_TOKEN secret is a fine-grained PAT from intervene-ci scoped to soundcloud/intervene with contents:write + issues:write.

How To Test

Merge and wait for the next releasable commit on master. The release workflow should complete the full cycle: analyze commits, update CHANGELOG, bump version, push to master, publish to npm, and create a GitHub Release.

Made with Cursor

GITHUB_TOKEN cannot push to protected branches regardless of push
restriction settings. Switch back to CI_TOKEN (fine-grained PAT from
intervene-ci, which is in the push restrictions) for semantic-release
git and API operations. Keep GITHUB_TOKEN id-token:write for npm OIDC
provenance.

Made-with: Cursor
@pablofmena pablofmena self-assigned this Apr 6, 2026
@pablofmena pablofmena requested a review from a team April 6, 2026 09:34
@gemini-code-assist
Copy link
Copy Markdown

Note

Gemini is unable to generate a review for this pull request due to the file types involved not being currently supported.

@pablofmena pablofmena merged commit c1a0337 into master Apr 6, 2026
7 checks passed
@pablofmena pablofmena deleted the pablomena/fix/release-ci-token-asahf branch April 6, 2026 09:36
@intervene-ci
Copy link
Copy Markdown
Collaborator

🎉 This PR is included in version 5.0.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

2 participants