From 2af991dc0b2440bd20e075e030cead8377762263 Mon Sep 17 00:00:00 2001 From: Pierre Labastie Date: Fri, 31 Oct 2014 10:08:40 +0000 Subject: [PATCH] Allow "wget --version" to return a missing version field, since only wget presence is required --- common/libs/func_check_version.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/common/libs/func_check_version.sh b/common/libs/func_check_version.sh index 9815880..99869f3 100644 --- a/common/libs/func_check_version.sh +++ b/common/libs/func_check_version.sh @@ -193,7 +193,10 @@ inline_doc WGET_LOC="$(whereis -b wget | cut -d" " -f2)" if [ -x $WGET_LOC ]; then wgetVer="$(wget --version | head -n1 | cut -d" " -f3)" - check_version "1.0.0" "${wgetVer}" "WGET" + if echo "$wgetVer" | grep -q '^[[:digit:]]'; then + check_version "1.0.0" "${wgetVer}" "WGET" + else echo Wget detected, but no version found. Continuing anyway. + fi else echo "${nl_}\"${RED}wget${OFF}\" ${BOLD}must be installed on your system for jhalfs to run" exit 1