proposal: retention by count and by day, week and month #437

Open
opened 2026-11-11 01:02:06 +01:00 by clawbot · 0 comments
Collaborator

From the acceptance test (#418): a basic a user of a backup tool expects and does not find.

What is missing

snapshot purge and --prune offer two policies: keep only the newest snapshot of each name, or keep everything newer than a duration. There is no "keep the last 7", and no "keep 7 daily, 4 weekly, 12 monthly".

Why a user expects it

The README's cron line keeps a four-week window, after which a file deleted five weeks ago is gone. Users of restic and borg run --keep-daily 7 --keep-weekly 4 --keep-monthly 12 and expect the same shape here; a count-based --keep-last N is the simplest safety net against a cron job that runs too often.

What it would take

A selection function over the per-name snapshot list, used by snapshot purge and snapshot create --prune: --keep-last N, --keep-daily N, --keep-weekly N, --keep-monthly N, combinable with --keep-newer-than. No change to the destination layout or the index; snapshots already carry their timestamps.

Model: fable-5-1

From the acceptance test (https://git.eeqj.de/sneak/vaultik/issues/418): a basic a user of a backup tool expects and does not find. **What is missing** `snapshot purge` and `--prune` offer two policies: keep only the newest snapshot of each name, or keep everything newer than a duration. There is no "keep the last 7", and no "keep 7 daily, 4 weekly, 12 monthly". **Why a user expects it** The README's cron line keeps a four-week window, after which a file deleted five weeks ago is gone. Users of restic and borg run `--keep-daily 7 --keep-weekly 4 --keep-monthly 12` and expect the same shape here; a count-based `--keep-last N` is the simplest safety net against a cron job that runs too often. **What it would take** A selection function over the per-name snapshot list, used by `snapshot purge` and `snapshot create --prune`: `--keep-last N`, `--keep-daily N`, `--keep-weekly N`, `--keep-monthly N`, combinable with `--keep-newer-than`. No change to the destination layout or the index; snapshots already carry their timestamps. Model: fable-5-1
sneak was assigned by clawbot 2026-11-11 01:02:06 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sneak/vaultik#437