From: Joel Rosdahl Date: Sun, 26 Jul 2020 18:19:45 +0000 (+0200) Subject: Improve documentation of --evict-older-than X-Git-Tag: v4.0~289 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e04ee56cf11441edd6b6bfad0f957b23cede62e7;p=thirdparty%2Fccache.git Improve documentation of --evict-older-than --- diff --git a/doc/MANUAL.adoc b/doc/MANUAL.adoc index c4bbad56f..b6f973146 100644 --- a/doc/MANUAL.adoc +++ b/doc/MANUAL.adoc @@ -94,15 +94,10 @@ Common options Clear the entire cache, removing all cached files, but keeping the configuration file. -*`--evict-older-than`* _NUM_:: - - This is another cleanup mechanism (independent of max_files and max_size). - It instructs ccache to perform cleanup based on age of the stored files. - The value _NUM_ is duration and means any cache entry older than it from CURRENT_TIME - should be deleted. _NUM_ should be an unsigned number with a suffix: - d(ays)/s(econds). - This cleanup can be performed from the cli with this option only. During the - cleanup max_files/max_size will not be taken into consideration. +*`--evict-older-than`* _AGE_:: + + Remove files older than _AGE_ from the cache. _AGE_ should be an unsigned + integer with a `d` (days) or `s` (seconds) suffix. *`-h`*, *`--help`*:: diff --git a/src/ccache.cpp b/src/ccache.cpp index 4e8df4fb6..7e23c5201 100644 --- a/src/ccache.cpp +++ b/src/ccache.cpp @@ -85,42 +85,40 @@ static const char USAGE_TEXT[] = compiler [compiler options] (via symbolic link) Common options: - -c, --cleanup delete old files and recalculate size counters - (normally not needed as this is done - automatically) - -C, --clear clear the cache completely (except configuration) - --evict-older-than N delete files older than N (days/seconds) (this will not - take max_files, max_size into consideration). - N should be an unsigned number with a suffix: - d(ays)/s(econds). - -F, --max-files NUM set maximum number of files in cache to NUM (use 0 - for no limit) - -M, --max-size SIZE set maximum size of cache to SIZE (use 0 for no - limit); available suffixes: k, M, G, T (decimal) - and Ki, Mi, Gi, Ti (binary); default suffix: G - -X, --recompress LEVEL recompress the cache to LEVEL (integer level or - "uncompressed") - -o, --set-config KEY=VAL set configuration item KEY to value VAL - -x, --show-compression show compression statistics - -p, --show-config show current configuration options in - human-readable format - -s, --show-stats show summary of configuration and statistics - counters in human-readable format - -z, --zero-stats zero statistics counters - - -h, --help print this help text - -V, --version print version and copyright information + -c, --cleanup delete old files and recalculate size counters + (normally not needed as this is done + automatically) + -C, --clear clear the cache completely (except configuration) + --evict-older-than AGE remove files older than AGE (unsigned integer + with a d (days) or s (seconds) suffix) + -F, --max-files NUM set maximum number of files in cache to NUM (use + 0 for no limit) + -M, --max-size SIZE set maximum size of cache to SIZE (use 0 for no + limit); available suffixes: k, M, G, T (decimal) + and Ki, Mi, Gi, Ti (binary); default suffix: G + -X, --recompress LEVEL recompress the cache to LEVEL (integer level or + "uncompressed") + -o, --set-config KEY=VAL set configuration item KEY to value VAL + -x, --show-compression show compression statistics + -p, --show-config show current configuration options in + human-readable format + -s, --show-stats show summary of configuration and statistics + counters in human-readable format + -z, --zero-stats zero statistics counters + + -h, --help print this help text + -V, --version print version and copyright information Options for scripting or debugging: - --dump-manifest PATH dump manifest file at PATH in text format - --dump-result PATH dump result file at PATH in text format - --extract-result PATH extract data stored in result file at PATH to the - current working directory - -k, --get-config KEY print the value of configuration key KEY - --hash-file PATH print the hash (160 bit BLAKE3) of the file at - PATH - --print-stats print statistics counter IDs and corresponding - values in machine-parsable format + --dump-manifest PATH dump manifest file at PATH in text format + --dump-result PATH dump result file at PATH in text format + --extract-result PATH extract data stored in result file at PATH to the + current working directory + -k, --get-config KEY print the value of configuration key KEY + --hash-file PATH print the hash (160 bit BLAKE3) of the file at + PATH + --print-stats print statistics counter IDs and corresponding + values in machine-parsable format See also . )";