feat: add claudebox list, with snapshot labels
#9
No reviewers
Labels
No labels
blocked
blocker:ci-red
blocker:conflict
blocker:drill-pending
blocker:unrequested
bug
claimed
documentation
enhancement
epic
merge-next
needs-triage
ready
release
scope:cli
scope:drill
scope:host
scope:installer
scope:templates
scope:tiers
stale
state:addressing
state:bots-reviewing
state:building
state:needs-human
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: heavy-duty/box#9
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/list-command"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #7.
statuswas the only way to see your boxes, and it was misnamed, silentlyignored the
<box>argument its own help advertised, and could not show you asnapshot label — the one thing the README's headline snapshot→clone flow
requires you to know. Meanwhile
claudebox list, the command everyone actuallytypes, printed the help and exited 0.
What's here
list <box>closes the snapshot gap: labels, plus the exact--fromline tocopy — the two halves of the README workflow finally meet.
no boxes yet — create one with: claudebox new --name work);an unknown box is an error on stderr, not empty output.
--jsonpasses Incus's JSON straight through;--remoteis honored.statuskeeps working as a deprecated alias (stderr note), so nobody's musclememory breaks. README updated.
Notes on the implementation
user.claudebox=1tag, so an Incusinstance claudebox didn't mint is never listed and never reached into — an
untagged instance is "no such box", not someone else's VM we start reporting on.
nstS) are all in Incus's own default column set, and noneof those fields can contain a comma or newline, so a plain
-F,split is safe.IPv4 is deliberately fetched separately: a box running docker has several
addresses, which Incus emits as a quoted multi-line CSV field — inlining it
garbles the table. The detail view takes the first address and strips Incus's
(iface)suffix.awkonly — notably notcolumn, which isn't installedon a stock Debian 13 cloud image).
Testing
⚠️ Not exercised against a real Incus daemon — I develop inside a claudebox,
which has no
incusand no nested virt. I drove every path against a stubbedincusreproducing its CSV output (including the multi-address docker case, astopped box with no IP, a snapshot-less box, an empty host, and
--remote), andasserted the exact argv reaching
incus:shellcheck bin/claudeboxadds no new findings (the two standing ones, SC2034and SC2015, are #8's). Worth a real smoke on a host with Incus before merge —
the thing I can't prove is that Incus's actual CSV matches the fixture.
🤖 Generated with Claude Code
Force-pushed:
listno longer takes a box. Per the discussion on #11, overloadinglist <box>as the detail view was the wrong shape — and it is what sent people reaching forincus infoin the first place.claudebox list— all your boxes. No positional.claudebox info <box>— one box: state, type, IP, snapshot labels,--fromline.claudebox list <box>— an error that points atinfo, rather than a silent surprise.statusstill forwards tolist. README and the (still hand-written) help follow; #10 rebased on top.Also worth noting for anyone hitting this:
claudebox list <box>printing the help with exit 0 is whatmaindoes with any unknown command — it is the headline symptom in #7, not a regression here. Nothing installable haslistuntil this merges.