From: Frederick Grose Date: Wed, 29 Mar 2023 14:29:39 +0000 (-0400) Subject: feat(lsinitrd): notify user on missing compressor X-Git-Url: http://git.ipfire.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=1300a930e76dbb380c7840760207296a1e58364c;p=thirdparty%2Fdracut.git feat(lsinitrd): notify user on missing compressor Provide a notice to user if the required compressor package is missing. This rather than failing silently. --- diff --git a/lsinitrd.sh b/lsinitrd.sh index b6f436cb4..987a6bfc3 100755 --- a/lsinitrd.sh +++ b/lsinitrd.sh @@ -342,6 +342,11 @@ case $bin in ;; esac +type "${CAT%% *}" > /dev/null 2>&1 || { + echo "Need '${CAT%% *}' to unpack the initramfs." + exit 1 +} + skipcpio() { $SKIP "$@" | $ORIG_CAT }