cm-publish

Publishes approved feature branches to main via squash PR or local merge with confirmation gates.

3|Updated Jan 29, 2026
One-click install
npx skills add https://github.com/PurdueRCAC/rcac-mcp --skill cm-publish-purduercac
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cm-publish
Source: https://github.com/PurdueRCAC/rcac-mcp/tree/main/.agents/skills/cm-publish
Command: npx skills add https://github.com/PurdueRCAC/rcac-mcp --skill cm-publish-purduercac

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Shipping an approved feature branch to main involves repetitive, error-prone steps: verifying the review verdict is still current, composing a rich PR body with artifact links, choosing squash-safe merge commands, and avoiding leaked commit messages. This Skill automates that final publishing step while keeping a human confirmation gate before any irreversible push or PR creation. ## Core Features & Use Cases - Review-gated publishing: Reads the verdict and last-reviewed commit from the spec's TECH.md and stops if code changed after approval, preventing unreviewed code from reaching main. - Rich PR generation: Builds a sectioned PR body (Summary, Goal, Design, Research, Phases, Verification) with SHA-pinned permalinks to spec artifacts instead of pasted copies. - Two landing modes: Default pushes the branch and opens a squash PR to main via gh; the local mode squash-merges into main and deletes the branch without touching the remote. - Use Case: After a code review approves your cluster-mcp feature branch, invoke the Skill to verify nothing changed since approval, confirm the PR title and body, and land the change on main as a single clean squash commit. ## Quick Start Ask the assistant to publish the current approved feature branch to main as a squash PR, confirming the title and body before pushing.

Frequently Asked Questions about cm-publish

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I merge an approved feature branch into main with a squash PR?

Invoke the Skill on the approved branch; it verifies the review verdict in TECH.md, composes a sectioned PR body with artifact permalinks, confirms with you, then pushes the branch and runs gh pr create against main. Adding the merge argument also squash-merges with an explicit subject.

How to squash merge a branch locally without opening a pull request?

Pass the local argument to squash-merge the branch into main on your machine and delete the branch. The Skill runs git merge --squash, commits with the PR-style title, and never pushes main unless you explicitly ask.

What happens if code changed after the review was approved?

The staleness gate diffs the last reviewed commit against HEAD excluding the spec directory; any non-spec change stops the publish and sends the branch back to review. You can only proceed with an explicit human override recorded in the PR body.

Does this workflow require the GitHub CLI?

The default PR mode uses gh for repo lookup, PR creation, and squash merging, so gh must be installed and authenticated. The local mode only needs git, since it merges and deletes the branch without any remote operation.

Can it create merge commits or use Conventional Commits titles?

No. The repository is squash-only, so merge commits and rebase-merges are forbidden, and PR titles follow a bracketed category plus imperative summary format rather than Conventional Commits prefixes like feat: or fix:.