1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-28 17:51:15 +02:00

* GC option `--max-atime' that specifies an upper limit to the last

accessed time of paths that may be deleted.  Anything more recently
  used won't be deleted.  The time is specified in time_t,
  e.g. seconds since 1970-01-01 00:00:00 UTC; use `date +%s' to
  convert to time_t from the command line. 

  Example: to delete everything that hasn't been used in the last two
  months:

  $ nix-store --gc -v --max-atime $(date +%s -d "2 months ago")
This commit is contained in:
Eelco Dolstra 2008-09-17 14:52:35 +00:00
parent 4af2fdba6d
commit f32fef1b07
4 changed files with 24 additions and 7 deletions

View file

@ -75,6 +75,10 @@ struct GCOptions
atime. */
bool useAtime;
/* Do not delete paths newer than `maxAtime'. -1 means no age
limit. */
time_t maxAtime;
GCOptions();
};