diff options
-rw-r--r-- | yarns/0040-generations.yarn | 13 | ||||
-rw-r--r-- | yarns/9000-implements.yarn | 5 |
2 files changed, 17 insertions, 1 deletions
diff --git a/yarns/0040-generations.yarn b/yarns/0040-generations.yarn index ccf9994f..4c9bf896 100644 --- a/yarns/0040-generations.yarn +++ b/yarns/0040-generations.yarn @@ -125,5 +125,16 @@ checking that the remaining one is the one we want. Forgetting generations according to a schedule (`obnam forget --keep`) ------------------------------------------------------------- -FIXME. +The normal way of forgetting generations is with the `obnam forget +--keep` option. + SCENARIO remove generations according to schedule + GIVEN 1kB of new data in directory L + WHEN user backs up directory L + GIVEN 1kB of new data in directory L + AND a manifest of directory L in M + WHEN user backs up directory L + AND user forgets according to schedule 1y + THEN user sees 1 generation + WHEN user restores their latest generation into X + THEN L, restored to X, matches manifest M diff --git a/yarns/9000-implements.yarn b/yarns/9000-implements.yarn index 57abe745..e711c6a3 100644 --- a/yarns/9000-implements.yarn +++ b/yarns/9000-implements.yarn @@ -121,6 +121,11 @@ Remove the oldest generation. id=$(run_obnam -r "$REPO" genids | head -n1 | grep .) run_obnam forget -r "$REPO" "$id" +Remove according to a `--keep` schedule. + + IMPLEMENTS WHEN user forgets according to schedule (\S+) + run_obnam forget -r "$REPO" --keep "$MATCH_1" + List generations ---------------- |