Usage:
axp revlib prune
[options]
Infoline:
Options:
-h, --help | display this help message and exit |
-n, --number ARG | leave ARG revisions, prune all others |
-s, --size ARG | leave ARG bytes, prune other revisions |
-a, --all | prune all revisions |
-t, --test | do not actually remove anything |
-v, --verbose ARG | be more verbose |
-q, --quiet | be quiet |
-o, --sort ARG | sort by ARG, see below |
-r, --reverse | reverse sorted revision list |
Revision libraries are very handy, but occupy disk space. It may be useful to keep the library of the constant size. One of the options --number, --size, --all should be given. Names of the revision fields to be used in the weighted sort: default|quasi-time, time|mtime, ctime, atime, btime (cache beginning time), name, size, random Examples: # keep the size of revision library at 50Mb at most axp revlib prune --size 50MB # keep at most 100 recent revisions in revision library axp revlib prune --number 100 --quiet # don't actually remove, list revisions to be pruned axp revlib prune --number 40 --test --verbose # a fancy way to report the number of library revisions axp revlib prune --test --all --sort random -v -v More examples: axp revlib prune --size 2GB --sort name --reverse axp revlib prune -s 2GB -o time -v -v This command may be run hourly or daily from a cronjob, like: 14 0/3 * * * /path/to/axp revlib prune -q -n 2000 14 1/3 * * * /path/to/axp revlib prune -q -s 5GB 14 2/3 * * * /path/to/axp revlib cleanup -q The exit status is 0 if any directories to be cleaned up are found, and 1 otherwise.