Fix release-tag workflow to push only annotated tags to main#87
Merged
data-douser merged 4 commits intomainfrom Feb 24, 2026
Merged
Fix release-tag workflow to push only annotated tags to main#87data-douser merged 4 commits intomainfrom
data-douser merged 4 commits intomainfrom
Conversation
The release-tag workflow checks out a commit (not a branch), leaving git in detached HEAD state. `git push origin HEAD` fails because git cannot resolve the bare `HEAD` symbolic ref to a remote branch name. Create a temporary local branch before committing and use an explicit refspec (`tmp/release-vX.Y.Z:refs/heads/main`) so the push is an unambiguous fast-forward to main.
Branch protection on main requires PRs, status checks, and code scanning — direct pushes are rejected. Instead of pushing the version-bump commit to main, commit it locally and push only the annotated tag ref. Downstream release jobs check out by tag so they receive the correct versioned code.
Branch protection on main requires PRs, status checks, and code scanning — direct pushes are rejected. Instead of pushing the version-bump commit to main, commit it locally and push only the annotated tag ref. Downstream release jobs check out by tag so they receive the correct versioned code.
…ql-development-mcp-server into dd/release-prep/5
Contributor
Dependency Review✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.Scanned FilesNone |
Contributor
There was a problem hiding this comment.
Pull request overview
This pull request modifies the release tagging workflow to comply with branch protection rules on the main branch. The key change is that version update commits are no longer pushed directly to main, but are instead made reachable only via the annotated release tag. Downstream release jobs continue to work correctly by checking out the tag reference.
Changes:
- Removed the push of version update commits to the main branch
- Updated comments to clarify that commits are intentionally not pushed to main due to branch protection rules
- Made the tag push syntax more explicit by using the full
refs/tags/prefix
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request updates the release tagging workflow to better comply with branch protection rules and clarify the process for tagging releases. The main change ensures that commits made during the release process are not pushed directly to the
mainbranch, but are instead referenced by a tag, which is then used for downstream release jobs.