diff --git a/common/func_check_version.sh b/common/func_check_version.sh index 84e6936..61e2c50 100644 --- a/common/func_check_version.sh +++ b/common/func_check_version.sh @@ -30,12 +30,6 @@ inline_doc # This saves us the save/restore hassle of the system IFS value local IFS -# if echo $ref_version | grep [[:alpha:]] 2>&1 >/dev/null || -# echo $tst_version | grep [[:alpha:]] 2>&1 >/dev/null ;then -# echo "Cannot test for text, 0.0.0a, version types, assuming 'success' " -# return -# fi - write_error_and_die() { echo -e "\n\t\t$TXT version -->${tst_version}<-- is too old. This script requires ${ref_version} or greater\n" @@ -43,7 +37,7 @@ inline_doc } echo -ne "$TXT:\t${L_arrow}${BOLD}${tst_version}${OFF}${R_arrow}" - IFS=".-(" # Split up w.x.y.z as well as w.x.y-rc (catch release candidates) + IFS=".-(p" # Split up w.x.y.z as well as w.x.y-rc (catch release candidates) set -- $ref_version # set postional parameters to minimum ver values ref_major=$1; ref_minor=$2; ref_revision=$3 # diff --git a/jhalfs b/jhalfs index 94a2bc0..c26b051 100755 --- a/jhalfs +++ b/jhalfs @@ -253,6 +253,7 @@ SUDO_LOC="`whereis -b sudo | cut -d " " -f2`" if [ -x $SUDO_LOC ]; then sudoVer=`sudo -V | head -n1 | cut -d " " -f3` echo "SUDO ${L_arrow}${BOLD}${sudoVer}${R_arrow}${OFF} ..OK" + check_version "1.0.0" "${sudoVer}" "SUDO" else echo "${nl_}\"${RED}sudo${OFF}\" ${BOLD}must be installed on your system for jhalfs to run" exit 1