relay-mergelisted
Install: claude install-skill sungjunlee/dev-relay
# Relay Merge
Use only for the supported GitHub route after `relay-review` records a passing verdict. A
local Reviewed Result closes through canonical recovery and never enters this
skill. Merge remains an explicit operator action; review bypasses and mutable-state overrides are not
part of the Relay contract.
## Inputs
- An immutable Relay `run.json` and append-only `events.jsonl`.
- The retained run worktree and its exact open PR.
- `--run-id` or an explicit `--run-dir`.
- Optional opaque operator identity, merge method, and operation id.
## Process
### 1. Read-only gate
```bash
RUN_ID=<run-id-from-dispatch>
node "${RELAY_SKILL_ROOT:-skills}/relay-merge/scripts/gate-check.js" \
--repo . --run-id "$RUN_ID" --json
```
The gate calls canonical Relay `inspect` and fails closed unless all of these
identify the same commit:
- live GitHub PR head and remote branch;
- retained worktree HEAD and Git tree;
- durable PR fact;
- passing verification fact;
- independent review fact and frozen Done Criteria hash.
If the derived action is not `merge`, follow that action. Never synthesize a
merge override from a PR comment, retired state, or missing evidence.
### 2. Explicit merge and cleanup
```bash
node "${RELAY_SKILL_ROOT:-skills}/relay-merge/scripts/finalize-run.js" \
--repo . --run-id "$RUN_ID" --merge-method squash --json
```
`finalize-run.js` repeats inspection after run-lock acquisition, issues a
durable merge authorization, invokes GitHub, revalidates
the exact mer