diff options
-rwxr-xr-x | bin/build-packages | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/bin/build-packages b/bin/build-packages index 80ba1ce..512c684 100755 --- a/bin/build-packages +++ b/bin/build-packages @@ -679,11 +679,14 @@ while [ "${count}" -ne 0 ] && \ # error, if the above build command already produced a # compressed package. # Since --ultra -20 seems too much for our i486 build vms, we - # silently fall back to -19 (without --ultra) if the higher + # silently fall back to lower compression levels if the higher # level fails. - find . -maxdepth 1 -type f -name '*.pkg.tar' \ - -not -execdir zstd --rm -T0 --ultra -20 '{}' -o '{}.zst' \; \ - -execdir zstd --rm -T0 -19 '{}' -o '{}.zst' \; + + # shellcheck disable=SC2086 + for options in '-T0 --ultra -20' '--ultra -20' {-19..-3}; do + find . -maxdepth 1 -type f -name '*.pkg.tar' \ + -execdir zstd --rm ${options} '{}' -o '{}.zst' \; + done # package files, that still exist, threw an error upon compression errors=$( find . -maxdepth 1 -type f -name '*.pkg.tar' |