delete removes snapshots from a space and deletes their manifest.db entries.
It does not delete CAS chunk files directly. Unreachable chunks are handled later by rinne gc.
Use --keep to keep the latest snapshots or snapshots newer than a day-based cutoff and delete the rest.
Usage
rinne delete <selector> [--space <space>]
rinne delete --keep <count|days> [--space <space>] [--dry-run]
Options
--space <space>
Use the specified space instead of the current space.
--keep <count|days>
Keep snapshots and delete the rest. A plain positive integer means latest snapshot count. A value ending with d means elapsed days from now.
--dry-run
Show delete targets without deleting. Only valid with --keep.
Examples
Delete the latest snapshot in the current space
rinne delete '@0' Delete a snapshot in another space
rinne delete '@0' --space experiment Delete by id prefix
rinne delete 20260308 Preview snapshots older than the latest 20 snapshots
rinne delete --keep 20 --dry-run Keep the latest 20 snapshots and delete older snapshots
rinne delete --keep 20 Preview snapshots older than the last 30 days in another space
rinne delete --keep 30d --space main --dry-run
Notes
- The command deletes the entire snapshots/<space>/<id>/ directory and the matching entry in .rinne/store/manifests/manifest.db.
- CAS chunk files are never deleted by delete itself.
- Snapshot directory cleanup is staged to .rinne/tmp/trash, and temporary trash cleanup is handled by rinne gc.
- --keep cannot be combined with a snapshot selector.
- --dry-run is only valid with --keep.
- 30d means exactly 30 * 24 hours, not calendar days. Day-based comparison uses snapshot CreatedUtc in UTC.