Pure regime logic in lib/merge.ts (detect/submit-plan/classify-land/handoff
schema+validation) behind a thin bin/gstack-merge CLI (detect/submit/wait/
write-state/read-state). Supports none, GitHub native merge queue, and the
trunk.io merge queue with a comment-first submit chain. 41 deterministic
tests (30 unit + 11 CLI).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>