Skip to content

🔒 fix(ci): split release workflow for proper credential scoping#158

Merged
gaborbernat merged 1 commit into
mainfrom
fix/icon-compatibility
Mar 31, 2026
Merged

🔒 fix(ci): split release workflow for proper credential scoping#158
gaborbernat merged 1 commit into
mainfrom
fix/icon-compatibility

Conversation

@gaborbernat

Copy link
Copy Markdown
Member

The post-release PR step in the release workflow fails with fatal: could not read Username because persist-credentials: false was added by the zizmor security audit (#154), but the step needs git push access via RELEASE_TOKEN.

The fix splits the release workflow into two jobs. The publish job keeps persist-credentials: false since it only needs to build and publish — no git push. The post-release job also uses persist-credentials: false but configures git auth via remote set-url scoped to the single step that needs push access, with RELEASE_TOKEN protected by the release environment.

The changelog patching is replicated in the post-release job so the version bump PR includes the updated CHANGELOG.md, matching the original behavior.

The post-release PR step failed because persist-credentials was set to
false (added by zizmor audit) but the step needed git push access via
RELEASE_TOKEN.

Split publish and post-release into separate jobs so credentials are
only persisted where git push is needed, and the RELEASE_TOKEN is
scoped to the release environment.
@gaborbernat gaborbernat added the bug Something isn't working label Mar 31, 2026
@gaborbernat gaborbernat enabled auto-merge (squash) March 31, 2026 18:53
@gaborbernat gaborbernat merged commit 3eb584c into main Mar 31, 2026
10 checks passed
@gaborbernat gaborbernat deleted the fix/icon-compatibility branch March 31, 2026 18:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant