Merge Commands
Need User FeedbackAll distributed workflow operations are slash commands executed by the AI agent. There are no CLI commands for merge — the AI agent is essential for genome conflict resolution and source merge guidance.
Primary Commands
/reap.pull <branch>The one-stop command for distributed merging. Fetches the remote, detects new generations on the target branch, creates a merge generation, and runs the full merge lifecycle. This is the distributed equivalent of /reap.evolve.
/reap.merge <branch>Run a full merge generation for a local branch. No fetch — ideal for worktree-based parallel development. The local equivalent of /reap.pull.
/reap.pushValidates REAP state (warns if a generation is in progress) and pushes the current branch. Use after completing a generation.
Stage Commands (Fine-Grained Control)
/reap.merge.startCreate a merge generation for a target branch. Runs detect and generates 01-detect.md.
/reap.merge.detectReview the divergence report. Re-run if needed.
/reap.merge.mateResolve genome conflicts interactively with the human.
/reap.merge.mergeRun git merge --no-commit and resolve source conflicts.
/reap.merge.reconcileVerify genome-source consistency. AI compares genome and source, user confirms inconsistencies.
/reap.merge.validationRun mechanical testing (bun test, tsc, build). Regress on failure.
/reap.merge.completionCommit and archive the merge generation.
/reap.merge.evolveRun the merge lifecycle from the current stage to completion.
Merge Hooks
| Event | When it fires |
|---|---|
| onMergeStarted | After /reap.merge.start creates a merge generation |
| onMergeDetected | After detect stage completes |
| onMergeMated | After mate stage completes (genome resolved) |
| onMergeMerged | After merge stage completes (source merged) |
| onMergeReconciled | After reconcile stage completes (genome-source consistency verified) |
| onMergeValidated | After merge validation completes |
| onMergeCompleted | After merge completion + archiving |
| onMergeTransited | After any merge stage transition (generic) |
onMergeTransited fires on every merge stage transition, similar to onLifeTransited for normal lifecycle.
