comet archive is the stable deterministic archive command. A mutating archive requires a verified change and recorded final confirmation; --dry-run can preview the operation before confirmation.
What it does
- Validates the change name and locates active or partially archived state.
- Requires
phase: archiveandverify_result: passfor both modes. - Checks the dated archive destination.
- For
--dry-run, reports the preview without requiring final confirmation or writing a pending action. - For a real archive, requires
archive_confirmation: confirmedand writes a recoverable pending checkpoint. - Calls
openspec archive <change> --yesto merge delta semantics and move the change. - Validates that main specs contain no delta-only headings.
- Idempotently annotates the Design Doc and Plan, preserving a clean Markdown EOF.
- Marks the change archived, completes Run state, and clears pending state.
comet state transition <name> archive-confirm. Reopening archive clears the old confirmation. Do not edit archive_confirmation or archived directly.
The command does not commit or push. Before running it, the Archive Skill confirms an immediate push or push plus PR. After success, the Skill writes branch_status: handled, runs the archive guard, and creates and pushes one complete commit containing the change move, main-spec merge, artifact annotations, and final state. Archived docs/superpowers/ pointers remain rooted at the project, so the Dashboard can still display Design Docs, Plans, and verification reports.
The packaged
comet-archive.mjs launcher remains for compatibility. Prefer
comet archive in user and agent instructions.
