Add `entire doctor rewrite-checkpoints` (re-materialize branch checkpoints as refs)
Commit

A second, data-copying migration alongside the byte-identical migrate-checkpoints. RewriteBranchToRefs re-drives the git-refs store's write path for every checkpoint on the v1 branch:
- Per session it replays the transcript (regenerating the compact transcript.jsonl), prompts, and metadata through Write, so the tree is rooted at the checkpoint (no shard folders) and SessionFilePaths/CompactTranscriptStart are correct by construction. Per-session summaries and combined attribution are replayed too; a tasks/ subtree is grafted in unchanged.
- The checkpoint id is preserved, and each commit keeps the original author — read from the v1-branch commit that wrote the session (metadata carries no author), falling back to the repo git author.
- Fresh commits copy the data; the branch's own commits are not reused.
Idempotent: existing refs are skipped unless --force re-materializes them. --dry-run reports without writing. Push follows the same policy as migrate-checkpoints: interactive asks, non-interactive never pushes.
Co-Authored-By: Claude Opus 4.8 (1M context) noreply@anthropic.com Entire-Checkpoint: 75925b9fdc24
Checkpoints
Checkpoint 1