| name | publish-release |
| description | Guide the post-merge release process - release branch, tag, vendor archive, and GitHub release |
Publish Release
Guide the post-merge release process for Afterburn. This skill runs automatable steps directly and prompts the user for steps requiring credentials (GPG signing, crates.io publishing).
What it does
- Verifies the pre-release PR has been merged
- Runs clean build verification with vendored dependencies
- Creates the release branch and guides user through
cargo release
- Opens the release PR
- After merge, pushes the tag and guides user through
cargo publish
- Creates the vendor archive with SHA256 digests
- Drafts the GitHub release body
- Cleans up local and remote branches
Prerequisites
- The pre-release PR for this version must already be merged to
main
cargo-release installed (cargo install cargo-release)
cargo-vendor-filterer installed (cargo install cargo-vendor-filterer)
- GPG key configured for commit/tag signing
- crates.io account with publish access
gh CLI installed and authenticated
Usage
/publish-release 5.11.0
/publish-release 5.11.0 --remote origin
Workflow
This is a multi-phase, interactive workflow. The skill runs what it can automatically and prompts the user at credential-gated steps. Track progress with a checklist displayed after each phase.
Step 1: Gather Inputs
Get the release version from arguments. If not provided, ask the user.
Set UPSTREAM_REMOTE from --remote flag, defaulting to origin.
Step 2: Verify Prerequisites
Run these checks:
cargo release --version
cargo vendor-filterer --help 2>&1 | head -1
If either is missing, offer to install:
cargo install cargo-release cargo-vendor-filterer
Then verify the pre-release was merged:
git checkout main
git pull ${UPSTREAM_REMOTE} main
git log --oneline -5
If the pre-release commits are not found, warn the user and stop. They need to run /prepare-release first.
Step 3: Clean Build Verification
Display: "Phase 1: Clean Build Verification"
Run these commands sequentially:
cargo vendor-filterer target/vendor
cargo test --all-features --config 'source.crates-io.replace-with="vv"' --config 'source.vv.directory="target/vendor"'
cargo clean
git clean -fd
If any step fails, report the error and stop. The build must be clean before proceeding.
Step 4: Create Release Branch
Display: "Phase 2: Create Release Commit and Tag"
git checkout -b release-${RELEASE_VER}
Now instruct the user to run cargo release manually, because it requires GPG signing and interactive confirmation:
Please run the following command in your terminal:
cargo release --execute ${RELEASE_VER}
This will:
- Update version in Cargo.toml to ${RELEASE_VER}
- Create a signed commit: "cargo: Afterburn release ${RELEASE_VER}"
- Create a signed tag: v${RELEASE_VER}
Confirm the version when prompted. Let me know when it completes.
Use the question tool to ask the user if it completed successfully.
After confirmation, verify:
git log --oneline -1
grep "^version = \"${RELEASE_VER}\"$" Cargo.toml
git tag --list "v${RELEASE_VER}"
If verification fails, report what went wrong.
Step 5: Push and Open Release PR
Display: "Phase 3: Release PR"
git push ${UPSTREAM_REMOTE} release-${RELEASE_VER}
Open the PR:
gh pr create \
--title "Release ${RELEASE_VER}" \
--body "$(cat <<'EOF'
Release PR for Afterburn ${RELEASE_VER}.
This PR should contain exactly one commit updating the version in Cargo.toml.
EOF
)"
Verify the PR has exactly one commit:
git log main..release-${RELEASE_VER} --oneline
Tell the user:
Release PR opened: {PR_URL}
Please:
1. Verify the PR contains exactly one commit
2. Get it reviewed and approved
3. Merge the PR
4. Come back here to continue
Let me know when the PR is merged.
Use the question tool to wait for the user.
Step 6: Publish Tag
Display: "Phase 4: Publish Artifacts"
After user confirms PR is merged:
git checkout v${RELEASE_VER}
Verify version:
grep "^version = \"${RELEASE_VER}\"$" Cargo.toml
Push the tag:
git push ${UPSTREAM_REMOTE} v${RELEASE_VER}
Now instruct the user to publish to crates.io:
Please run the following command to publish to crates.io:
cargo publish
This requires your crates.io authentication token.
Let me know when it completes.
Use the question tool to wait for the user.
Step 7: Vendor Archive
Display: "Phase 5: Vendor Archive"
cargo vendor-filterer --format=tar.gz --prefix=vendor target/afterburn-${RELEASE_VER}-vendor.tar.gz
Compute digests:
sha256sum target/package/afterburn-${RELEASE_VER}.crate
sha256sum target/afterburn-${RELEASE_VER}-vendor.tar.gz
Store the digest values to include in the GitHub release.
Step 8: Draft GitHub Release
Display: "Phase 6: GitHub Release"
Read the release notes for this version from docs/release-notes.md. Extract the section between ## Afterburn ${RELEASE_VER} and the next ## header.
Present to the user:
Please create a GitHub release:
1. Go to: https://github.com/coreos/afterburn/tags
2. Find tag v${RELEASE_VER}, click the three-dot menu, and create a release
3. Paste the following changelog:
---
{extracted release notes}
---
4. Upload: target/afterburn-${RELEASE_VER}-vendor.tar.gz
5. Include these digests in the release description:
sha256sum afterburn-${RELEASE_VER}.crate: {digest}
sha256sum afterburn-${RELEASE_VER}-vendor.tar.gz: {digest}
6. Publish the release
Let me know when done.
Use the question tool to wait for the user.
Step 9: Cleanup
Display: "Phase 7: Cleanup"
cargo clean
git checkout main
git pull ${UPSTREAM_REMOTE} main
git push ${UPSTREAM_REMOTE} :pre-release-${RELEASE_VER} :release-${RELEASE_VER}
git branch -d pre-release-${RELEASE_VER} release-${RELEASE_VER}
Step 10: Final Summary
Release ${RELEASE_VER} complete!
Completed steps:
[x] Clean build verification
[x] Release commit and tag (cargo release)
[x] Release PR merged
[x] Tag pushed to upstream
[x] Crate published to crates.io
[x] Vendor archive created
[x] GitHub release published
[x] Branches cleaned up
Remaining manual steps (Fedora/CentOS packaging):
[ ] Review Packit PR in Fedora: https://src.fedoraproject.org/rpms/rust-afterburn/pull-requests
[ ] Merge rawhide into relevant branches (e.g., f43) and run fedpkg build
[ ] Submit builds to bodhi
[ ] Submit fast-track for FCOS testing-devel
[ ] Submit fast-track for FCOS next-devel (if open)
[ ] Create rebase-c9s-afterburn issue (CentOS Stream 9)
[ ] Create rebase-c10s-afterburn issue (CentOS Stream 10)
Checklist Coverage
From the release checklist, this skill covers:
What's NOT covered
- GPG key setup or management
- crates.io account setup
- Fedora packaging (Packit PR review, bodhi submissions)
- CentOS Stream packaging (internal team process)
- FCOS fast-track submissions
Automation Boundaries
| Step | Automated? | Reason |
|---|
| cargo vendor-filterer, cargo test | Yes | Deterministic build commands |
| git checkout, push, branch, clean | Yes | Standard git operations |
| gh pr create | Yes | CLI-based |
| cargo release --execute | No | Requires GPG signing + interactive confirmation |
| cargo publish | No | Requires crates.io auth token |
| GitHub release creation | No | User should review changelog before publishing |
| sha256sum computation | Yes | Deterministic |
References
- Full release checklist:
.github/ISSUE_TEMPLATE/release-checklist.md
- cargo-release config:
Cargo.toml:14-20
- Example release PRs: #1224 (5.9.0), #1206 (5.8.2), #1200 (5.8.0)
- Release that needed a redo: v5.8.1 ("Re-release of 5.8.0 due to error")