Fold GitHub release steps into deploy.sh#50
Merged
Conversation
Add release-draft, release-cut, and release-abort subcommands so the release lifecycle (draft the GitHub release, publish it, delete the draft on failure) lives in the same single source of truth as the cache and Docker deploy steps. The Release workflow's draft-release, cut-release, and failure-cleanup steps now call these subcommands instead of inlining gh, and the CONTRIBUTING.md runbook uses them too. The runbook also now states that a manual release must be built from a commit on main, since kup resolves komet-node versions against main.
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.
Why
PR #49 made
scripts/deploy.shthe single source of truth for the cache and Docker deploy steps, but the GitHub-release lifecycle (draft → publish, plus failure cleanup) was still inlined as rawghcalls inrelease.ymland duplicated in the runbook. This folds those steps into the script too.What
scripts/deploy.sh— three new subcommands wrapping theghcalls the workflow makes:release-draft—gh release create v<version> --draft --title … --target <REV>release-cut—gh release edit v<version> --draft=falserelease-abort—gh release delete v<version> --yes --cleanup-tag(best-effort; for the failure path)They authenticate through
ghitself (login orGH_TOKEN/GITHUB_TOKEN), so no secret is read directly.release-drafttargetsREV, which must be the deployed commit..github/workflows/release.yml—draft-release,cut-release, and bothOn failure, delete drafted releasesteps now call the script instead of inlininggh. Dropped theset -xfrom those steps (the script warns against tracing) and the unusedmake-releasestep output.CONTRIBUTING.md— the runbook uses the new subcommands, and now states that a manual release must be built from a commit onmain, since kup resolves komet-node versions againstmain(the gap that made a branch-built version invisible tokup list).Verification
bash -nclean;--helprenders the new subcommands.ghinvocation by shadowingghwith a stub — they match the workflow's originals.ghcalls are argument-for-argument identical to the previous inline commands.