feat(bin): mt-land pins, --check, --json for the prs board #61

Merged
jmz merged 6 commits from maximus/mt-land-pins into master 2026-11-24 20:18:26 +00:00 AGit
Member

mt-land hardening for the prs board (plan nixos-hosts …/plans/2026-11-24-prs-service-interface.md, Tasks 7-9; spec §7 R1).

  • --json, result codes, exits: --json prints exactly one object with a code. Exit 0 merged (or would merge), 3 refused, 2 usage, 1 error. A catch-all covers unexpected exceptions, and plain-mode errors go through clean().
  • Pins: --tip <sha> / --pr N refuse with tip_mismatch / pr_mismatch when the train grew (§5.10 extension) or was rebuilt between "Bear looked" and "Bear landed". The merge's head_commit_id is the pinned tip.
  • --check: runs every check and never POSTs.
  • Fixed origin: ORIGIN = https://git.mirus-tech.com. FORGEJO_URL can only match it, never redirect the token.
  • Token user: must be jmz (token_user), checked before any PR read.
  • Lost merge reply: after a lost reply (drop, reset, IncompleteRead) it re-reads, never re-POSTs. It reports merged (recovered: true) only if the PR is merged AND the base is at the pinned tip. A no-answer failure that is not merged yet is unknown, with the PR URL to check.
  • CI: the mt-land tests now run in CI.

Tests: 37 OK. Reviewed per task and in a final whole-branch review (Opus), plus one fix wave.

🤖 Generated with Claude Code

https://claude.ai/code/session_01XMf4ELSbWvtUkEeVky4wWr

mt-land hardening for the `prs` board (plan nixos-hosts …/plans/2026-11-24-prs-service-interface.md, Tasks 7-9; spec §7 R1). - **`--json`, result codes, exits:** `--json` prints exactly one object with a `code`. Exit 0 merged (or would merge), 3 refused, 2 usage, 1 error. A catch-all covers unexpected exceptions, and plain-mode errors go through `clean()`. - **Pins:** `--tip <sha>` / `--pr N` refuse with `tip_mismatch` / `pr_mismatch` when the train grew (§5.10 extension) or was rebuilt between "Bear looked" and "Bear landed". The merge's `head_commit_id` is the pinned tip. - **`--check`:** runs every check and never POSTs. - **Fixed origin:** `ORIGIN = https://git.mirus-tech.com`. `FORGEJO_URL` can only match it, never redirect the token. - **Token user:** must be jmz (`token_user`), checked before any PR read. - **Lost merge reply:** after a lost reply (drop, reset, IncompleteRead) it re-reads, never re-POSTs. It reports `merged` (`recovered: true`) only if the PR is merged AND the base is at the pinned tip. A no-answer failure that is not merged yet is `unknown`, with the PR URL to check. - **CI:** the mt-land tests now run in CI. Tests: 37 OK. Reviewed per task and in a final whole-branch review (Opus), plus one fix wave. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01XMf4ELSbWvtUkEeVky4wWr
maximus changed title from fix(mt-land): unanswered merge that is not merged is unknown; guard non-dict re-reads to feat(bin): mt-land pins, --check, --json for the prs board 2026-11-24 17:48:14 +00:00
maximus force-pushed maximus/mt-land-pins from 804345a56c
Some checks were skipped
ci / gate (pull_request) Has been skipped
to a6d5432f4d
Some checks were skipped
ci / gate (pull_request) Has been skipped
2026-11-24 20:15:06 +00:00
Compare
jmz merged commit a6d5432f4d into master 2026-11-24 20:18:26 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
public/dotfiles-public!61
No description provided.