Agent skill
release-rulez
RuleZ release workflow automation. Use when asked to "release RuleZ", "create a release", "prepare release", "tag version", "hotfix release", or "publish RuleZ". Covers version management from Cargo.toml, changelog generation from conventional commits, PR creation, tagging, hotfix workflows, and GitHub Actions release monitoring.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/release-rulez
Metadata
Additional technical details for this skill
- project
- rulez
- version
- 1.0.0
- source of truth
- Cargo.toml
SKILL.md
release-rulez
Contents
- Overview
- Decision Tree
- Phase 1: Prepare Release
- Phase 2: Execute Release
- Phase 3: Verify Release
- Phase 4: Hotfix Release
- Scripts Reference
- References
Overview
Single Source of Truth: Version is stored in Cargo.toml (workspace root):
[workspace.package]
version = "1.0.0"
Release Trigger: Pushing a tag like v1.0.0 triggers .github/workflows/release.yml
Build Targets:
| Platform | Target | Asset |
|---|---|---|
| Linux x86_64 | x86_64-unknown-linux-gnu | rulez-linux-x86_64.tar.gz |
| Linux ARM64 | aarch64-unknown-linux-gnu | rulez-linux-aarch64.tar.gz |
| macOS Intel | x86_64-apple-darwin | rulez-macos-x86_64.tar.gz |
| macOS Apple Silicon | aarch64-apple-darwin | rulez-macos-aarch64.tar.gz |
| Windows | x86_64-pc-windows-msvc | rulez-windows-x86_64.exe.zip |
Repository: SpillwaveSolutions/code_agent_context_hooks
Decision Tree
What do you need?
|
+-- Starting a new release? --> Phase 1: Prepare Release
|
+-- PR merged, ready to tag? --> Phase 2: Execute Release
|
+-- Tag pushed, checking status? --> Phase 3: Verify Release
|
+-- Need to patch an existing release? --> Phase 4: Hotfix Release
|
+-- Something went wrong? --> references/troubleshooting.md
Phase 1: Prepare Release
1.1 Read Current Version
# Run from repo root
.claude/skills/release-rulez/scripts/read-version.sh
# Output: 1.0.0
1.2 Determine New Version
Follow semantic versioning:
- MAJOR (X.0.0): Breaking changes
- MINOR (x.Y.0): New features, backwards compatible
- PATCH (x.y.Z): Bug fixes only
Update Cargo.toml (manual step):
[workspace.package]
version = "1.1.0" # <- Update this
1.3 Create Release Branch
VERSION=$(.claude/skills/release-rulez/scripts/read-version.sh)
git checkout -b release/v${VERSION}
1.4 Run Pre-flight Checks
.claude/skills/release-rulez/scripts/preflight-check.sh
This validates:
- Clean working directory (or only release files modified)
- All unit tests pass (
cargo test) - All integration tests pass (
task integration-test) - Clippy has no warnings
- Format check passes
IMPORTANT: Integration tests are REQUIRED before any release.
1.5 Generate Changelog
VERSION=$(.claude/skills/release-rulez/scripts/read-version.sh)
.claude/skills/release-rulez/scripts/generate-changelog.sh ${VERSION}
1.6 Commit and Push
VERSION=$(.claude/skills/release-rulez/scripts/read-version.sh)
git add CHANGELOG.md Cargo.toml
git commit -m "chore: prepare v${VERSION} release"
git push -u origin release/v${VERSION}
1.7 Create Release PR
VERSION=$(.claude/skills/release-rulez/scripts/read-version.sh)
gh pr create --title "chore: prepare v${VERSION} release" --body "..."
1.8 Monitor CI and Auto-Merge
Use /loop to poll PR checks every 5 minutes. When all checks pass, automatically merge and continue to Phase 2 (tag and push).
/loop 5m check PR #<PR_NUMBER> status: run `gh pr checks <PR_NUMBER>`. If all checks pass, merge with `gh pr merge <PR_NUMBER> --squash --delete-branch`, then sync main (`git checkout main && git pull`), tag (`git tag v<VERSION> && git push origin v<VERSION>`), and verify the release workflow started. If checks are still pending, report status and wait. If any check failed, report the failure details and stop.
What the loop does each cycle:
- Runs
gh pr checks <PR_NUMBER>to get current status - If all checks pass -> auto-merges the PR, syncs main, creates and pushes the tag, verifies the release workflow triggered, then cancels the loop
- If checks are pending -> reports progress (N/M passing) and waits for next cycle
- If any check failed -> reports the failure, cancels the loop, and alerts the user
Important: The loop handles the full Phase 1.8 -> Phase 2 transition automatically. Once the tag is pushed, proceed to Phase 3 (verify) manually or set up another loop.
Phase 2: Execute Release
Note: If you used the
/loopauto-merge in Phase 1.8, Phase 2 is already done. Skip to Phase 3.
2.1 Merge the Release PR
gh pr merge <PR_NUMBER> --squash --delete-branch
2.2 Sync Local Main
git checkout main
git pull
2.3 Create and Push Tag
VERSION=$(.claude/skills/release-rulez/scripts/read-version.sh)
git tag v${VERSION}
git push origin v${VERSION}
Phase 3: Verify Release
3.1 Monitor Workflow
.claude/skills/release-rulez/scripts/verify-release.sh
3.2 Verify Release Assets
VERSION=$(.claude/skills/release-rulez/scripts/read-version.sh)
gh release view v${VERSION}
Phase 4: Hotfix Release
See hotfix-workflow.md for detailed steps.
Scripts Reference
| Script | Purpose | Usage |
|---|---|---|
read-version.sh |
Extract version from Cargo.toml | ./scripts/read-version.sh |
generate-changelog.sh |
Generate changelog from commits | ./scripts/generate-changelog.sh [version] |
preflight-check.sh |
Run all pre-release checks | ./scripts/preflight-check.sh [--json] |
verify-release.sh |
Monitor release workflow status | ./scripts/verify-release.sh [version] |
All scripts are located in .claude/skills/release-rulez/scripts/.
References
- release-workflow.md - Standard release workflow diagram
- hotfix-workflow.md - Hotfix release workflow diagram
- troubleshooting.md - Common issues and solutions
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?