Switch to different zip/pwgen exists bash check

This commit is contained in:
Clemens Schwaighofer
2022-11-04 10:43:47 +09:00
parent 54f4d69da6
commit 9f61b3c523

View File

@@ -58,12 +58,14 @@ if [ ! -d "${root_folder}${output_zip_folder}" ]; then
mkdir "${root_folder}${output_zip_folder}";
fi;
# check if password generate software is installed
if [ ! command -v pwgen &> /dev/null ]; then
# if [ ! command -v pwgen &> /dev/null ]; then
if [ -z $(command -v pwgen) ]; then
echo "Missing pwgen application, aborting";
exit;
fi;
# check for zip
if [ ! command -v zip &> /dev/null ]; then
# if [ ! command -v zip &> /dev/null ]; then
if [ -z $(command -v zip) ]; then
echo "Missing zip application, aborting";
exit;
fi;