1.9 KiB
1.9 KiB
CLI Surface and Mutating Operations Agenda
Status
Open
Purpose
Define the stable CLI contract for packer commands, especially commands that mutate registry state or user files.
Context
The draft already lists a substantial command surface:
initaddadoptforgetrmlistshowdoctorbuildwatchgcquarantine
This is enough surface area that command semantics need architectural review before turning into normative CLI specs.
Source Sections
13. CLI Commands (Comprehensive)
Key Questions
- Which commands are core v1 and which are aspirational?
- Which identifiers must every command accept: name, id, uuid, path?
- Which commands mutate registry only versus mutate workspace files?
- What requires confirmation, force flags, or dry-run support?
- How explicit should
--fixand auto-materialization behavior be? - Should CLI output contracts be stable for automation, or only JSON/structured output modes?
Options
Option A
Define a minimal stable v1 CLI and mark the rest as future or optional.
Option B
Freeze the larger command catalog immediately.
Tradeoffs
- Option A lowers the early compatibility burden.
- Option A gives room to validate mutating operations safely before promising too much.
- Option B gives a bigger product surface up front, but it increases long-term compatibility cost.
Recommendation
Adopt Option A and distinguish:
- required core commands,
- optional commands,
- future commands not yet in the normative CLI contract.
Expected Decisions to Produce
- Core v1 command set.
- Mutation safety model.
- Identifier resolution rules.
- Structured output and automation expectations.
Expected Spec Follow-up
- CLI command contract spec.
- Mutation and confirmation policy spec.
- Command output contract spec.
Non-Goals
- Asset payload binary layout.
- Format-specific
asset.jsonrules. - Detailed cache internals.