diff options
author | Jia Tan <jiat0218@gmail.com> | 2023-05-13 00:44:41 +0800 |
---|---|---|
committer | Jia Tan <jiat0218@gmail.com> | 2023-07-17 23:34:55 +0800 |
commit | a165d7df1964121eb9df715e6f836a31c865beef (patch) | |
tree | 54847aab6aa87d0c1fc9e6b128b759ebe528b019 /src/xz/args.c | |
parent | xz: Update the man page for --block-list and --filtersX (diff) | |
download | xz-a165d7df1964121eb9df715e6f836a31c865beef.tar.xz |
xz: Add a new --filters-help option.
The --filters-help can be used to help create filter chains with the
--filters and --filtersX options. The message in --long-help is too
short to fully explain the syntax to construct complex filter chains.
In --robot mode, xz will only print the output from liblzma function
lzma_str_list_filters.
Diffstat (limited to '')
-rw-r--r-- | src/xz/args.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/xz/args.c b/src/xz/args.c index 6ae3c96f..7af3e850 100644 --- a/src/xz/args.c +++ b/src/xz/args.c @@ -180,6 +180,7 @@ parse_real(args_info *args, int argc, char **argv) OPT_FILTERS7, OPT_FILTERS8, OPT_FILTERS9, + OPT_FILTERS_HELP, OPT_X86, OPT_POWERPC, @@ -261,6 +262,7 @@ parse_real(args_info *args, int argc, char **argv) { "filters7", optional_argument, NULL, OPT_FILTERS7}, { "filters8", optional_argument, NULL, OPT_FILTERS8}, { "filters9", optional_argument, NULL, OPT_FILTERS9}, + { "filters-help", optional_argument, NULL, OPT_FILTERS_HELP}, { "lzma1", optional_argument, NULL, OPT_LZMA1 }, { "lzma2", optional_argument, NULL, OPT_LZMA2 }, @@ -447,6 +449,12 @@ parse_real(args_info *args, int argc, char **argv) (size_t)(c - OPT_FILTERS)); break; + // --filters-help + case OPT_FILTERS_HELP: + // This doesn't return. + message_filters_help(); + break; + case OPT_X86: coder_add_filter(LZMA_FILTER_X86, options_bcj(optarg)); |