From: Michael Tremer Date: Mon, 18 Sep 2023 12:36:13 +0000 (+0000) Subject: compress-man-pages: Support already XZ compressed man pages X-Git-Tag: 0.9.30~1684 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4fcf50ddc5ec796008d873060b6b6c9d6c407692;p=pakfire.git compress-man-pages: Support already XZ compressed man pages Signed-off-by: Michael Tremer --- diff --git a/src/scripts/compress-man-pages b/src/scripts/compress-man-pages index 0ff079066..6a4560123 100644 --- a/src/scripts/compress-man-pages +++ b/src/scripts/compress-man-pages @@ -63,6 +63,11 @@ main() { file="${file%*.gz}" fi ;; + *.xz) + if xz -d "${file}"; then + file="${file%*.xz}" + fi + ;; esac # Say what we are doing... @@ -98,14 +103,14 @@ main() { # Strip any previous compression from link case "${link}" in - *.bz2|*.gz) + *.bz2|*.gz|*.xz) link="${link%.*}" ;; esac # Strip any previous compression from target case "${target}" in - *.bz2|*.gz) + *.bz2|*.gz|*.xz) target="${target%.*}" ;; esac