Finish PR — Git skill for Claude Code
Post-merge cleanup -- verify merge state, sync dev, delete branch, close issue.
How to install Finish PR
Installs to ~/.claude/commands/xencon-aixcl-finish-pr.md
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/xencon/aixcl/HEAD/.claude/commands/finish-pr.md -o ~/.claude/commands/xencon-aixcl-finish-pr.md Restart Claude Code, or start a new session, for it to be picked up.
What Finish PR does
description: Post-merge cleanup -- verify merge state, sync dev, delete branch, close issue
The human says a PR is merged. VERIFY IT FIRST -- humans are sometimes mistaken, and a PR can be CLOSED without being merged:
!`gh pr list --repo xencon/aixcl --state all --limit 5 --json number,state,title --jq '.[] | "#\(.number) \(.state) \(.title)"'`
For the PR in question (ask which one if ambiguous, or take it from $ARGUMENTS):
- Confirm the state is exactly
MERGED: `gh pr view --
Alternatives in Git
- GitHub Review PR — Use when a PR needs full review — resolves merge conflicts with the base first, then fixes CI failures, then a 1.5k ★
- Worktree Rm — Remove a git worktree and optionally delete its branch 387 ★
- Drive Acquisition — Work GitHub issues that drive acquisition — verify relevance, close stale ones, fan out at most two engineer a 324 ★
Full documentation available on GitHub
View Source RepositoryRelated Skills
PR Merged
Post-merge cleanup — checkout main, pull latest, delete the feature branch, and close the linked work item.
PR Post Merge
Clean up after a PR is merged — close fork issue, update local branch, delete issue branch
Hybrid Complete
Complete Hybrid Ralph task in worktree, verify all stories complete, commit code changes (excluding planning f
Autonomy Off
End autonomy mode — finish the in-flight slice to merge, start nothing new, then post a closing summary (merge
Post Merge
Execute post-merge actions including syncing main, re-running tests, and cleanup
Framework Init
Bootstrap the claude-code-framework into a repo that does not yet mount it — add the submodule, pick a profile
Related Agents
Branch Janitor
Post-merge cleanup agent — after the human confirms a PR/branch merge, removes stale agent worktrees, deletes
Autopilot Worker
Autopilot worker — implements ONE GitHub issue (or a BUNDLED BATCH of bundle-safe issues) end-to-end (version
Cleanup Phase 1
Runs phase 1 (dead code) and phase 1.5 (duplicate functions) of a codebase cleanup that is already under way.