feat(7): add a release skill with tested numbering logic#8
Merged
alanbchristie merged 1 commit intoJun 8, 2026
Merged
Conversation
Add a Claude Code 'release' skill (.claude/skills/release/) that cuts a release of the operator from the latest main: - Refuses to release when the 'build' CI run for the commit has not succeeded. - Enforces that the release major matches the pinned 'kubernetes' package. - Supports semver pre-releases (alpha/beta/rc, numbered from 1) marked as a GitHub Pre-release, and full releases. - Asks the user for a title and the channel, generates release notes from the commits since the prior release, and creates the GitHub release/tag. The numbering logic lives in a pure, unit-tested helper (next_release.py / tests/test_release.py) so it is deterministic across releases; the SKILL.md orchestrates the interactive, cluster-facing steps. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
Fixes #7
Adds a Claude Code
releaseskill (.claude/skills/release/) that providesthe repository's release logic.
What it does
main(fast-forward check).buildworkflow run forthe exact commit being released and refuses unless it succeeded.
alpha/beta/rcpre-releases(
X.Y.Z-channel.N, firstNis1) and full releases (X.Y.Z).kubernetespackage(
operator/requirements.txt) — enforced by the helper.--prerelease).(
gh release create --generate-notes).(alpha/beta/rc/final).
Design
The interactive, outward-facing orchestration (CI check, prompts, release
creation) lives in
SKILL.md. The deterministic, easy-to-get-wrong numberinglogic lives in a pure, unit-tested helper:
.claude/skills/release/next_release.py—kubernetes_major,next_tag,is_prerelease, plus a smallmajor/nextCLI the skill calls from a shell.tests/test_release.py— 14 tests (first-pre-release-is-1, per-channelincrementing, major-mismatch/ malformed-base/ unknown-channel rejection,
final-release-no-suffix and no-reuse).
Testing
TDD — tests written first. Full suite passes (45 tests: 31 existing + 14 new),
pre-commitis clean, and the helper type-checks undermypy --strict.🤖 Generated with Claude Code