The snapshot format was hardcoded in snapshot-libvirt-domains, so any tool
pruning zvirt's snapshots had to copy the same literal. On a mismatch,
zfs-autobackup selects the right datasets, matches none of their snapshots,
destroys nothing and still exits 0 - snapshots then accumulate forever while
the retention job reports success.
Move the format to a sourceable file, /usr/share/zvirt/snapshot-format, that
snapshot-libvirt-domains sources instead of hardcoding, so producer and
consumer cannot drift. Also expose it as --print-snapshot-format for consumers
that would rather not source a file.
Document the retention run, the deliberate absence of a {} placeholder (it is
what allows a single prune run to cover every domain), and the systemd
specifier escaping trap.
While here, fix the lint target: bin/*.sh matched no file, since neither
script carries a .sh extension.
Closes#1
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XaqxX5X9VGwQSvNEBYyZq1