Update mm-scripts.sh
This commit is contained in:
@@ -855,7 +855,7 @@ UPDATESERVICE(){
|
|||||||
[ ! -d /opt/Backups ] && mkdir /opt/Backups
|
[ ! -d /opt/Backups ] && mkdir /opt/Backups
|
||||||
|
|
||||||
echo -e "${idsCL[Green]}Done${idsCL[Default]}"
|
echo -e "${idsCL[Green]}Done${idsCL[Default]}"
|
||||||
|
|
||||||
if [ "${MM_UPDATE_REPO[${usrvc}]}" != "" ] && [ "${MM_UPDATE_REPO[${usrvc}]}" != "systemd" ]; then
|
if [ "${MM_UPDATE_REPO[${usrvc}]}" != "" ] && [ "${MM_UPDATE_REPO[${usrvc}]}" != "systemd" ]; then
|
||||||
|
|
||||||
msg="Finding latest update url"
|
msg="Finding latest update url"
|
||||||
@@ -874,7 +874,14 @@ UPDATESERVICE(){
|
|||||||
fi
|
fi
|
||||||
installed_ver=`echo ${latest_release_url} | cut -d/ -f8`
|
installed_ver=`echo ${latest_release_url} | cut -d/ -f8`
|
||||||
echo -e "${idsCL[Green]}Done${idsCL[Default]}"
|
echo -e "${idsCL[Green]}Done${idsCL[Default]}"
|
||||||
|
|
||||||
|
msg="Latest Version"; c=0; spc=''; spc1=$((${cw_spc}-${#msg})); until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done
|
||||||
|
echo -e "${idsCL[White]}${msg}${spc} : ${idsCL[Green]}${installed_ver}${idsCL[Default]}"
|
||||||
|
|
||||||
cver=${usrvc}_VER
|
cver=${usrvc}_VER
|
||||||
|
msg="Current Version"; c=0; spc=''; spc1=$((${cw_spc}-${#msg})); until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done
|
||||||
|
echo -e "${idsCL[White]}${msg}${spc} : ${idsCL[Green]}${!cver}${idsCL[Default]}"
|
||||||
|
|
||||||
if [ "${!cver}" != "${installed_ver}" ]; then
|
if [ "${!cver}" != "${installed_ver}" ]; then
|
||||||
msg="Installing version"; c=0; spc=''; spc1=$((${cw_spc}-${#msg})); until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done
|
msg="Installing version"; c=0; spc=''; spc1=$((${cw_spc}-${#msg})); until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done
|
||||||
echo -e "${idsCL[White]}${msg}${spc} : ${idsCL[Green]}${installed_ver}${idsCL[Default]}"
|
echo -e "${idsCL[White]}${msg}${spc} : ${idsCL[Green]}${installed_ver}${idsCL[Default]}"
|
||||||
@@ -952,12 +959,12 @@ UPDATESERVICE(){
|
|||||||
echo -e "${idsCL[Green]}${usrvc^} Service has been updated${idsCL[Default]}"
|
echo -e "${idsCL[Green]}${usrvc^} Service has been updated${idsCL[Default]}"
|
||||||
|
|
||||||
else
|
else
|
||||||
msg="Latest Version"; c=0; spc=''; spc1=$((${cw_spc}-${#msg})); until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done
|
# msg="Latest Version"; c=0; spc=''; spc1=$((${cw_spc}-${#msg})); until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done
|
||||||
echo -e "${idsCL[White]}${msg}${spc} : ${idsCL[Green]}${installed_ver}${idsCL[Default]}"
|
# echo -e "${idsCL[White]}${msg}${spc} : ${idsCL[Green]}${installed_ver}${idsCL[Default]}"
|
||||||
|
#
|
||||||
cver=${usrvc}_VER
|
# cver=${usrvc}_VER
|
||||||
msg="Current Version"; c=0; spc=''; spc1=$((${cw_spc}-${#msg})); until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done
|
# msg="Current Version"; c=0; spc=''; spc1=$((${cw_spc}-${#msg})); until [ $c = ${spc1} ]; do spc="${spc} "; c=`expr $c + 1`; done
|
||||||
echo -e "${idsCL[White]}${msg}${spc} : ${idsCL[Green]}${!cver}${idsCL[Default]}"
|
# echo -e "${idsCL[White]}${msg}${spc} : ${idsCL[Green]}${!cver}${idsCL[Default]}"
|
||||||
echo -e " ${idsCL[White]}Update Not Needed${idsCL[Green]}${installed_ver}${idsCL[Default]}"
|
echo -e " ${idsCL[White]}Update Not Needed${idsCL[Green]}${installed_ver}${idsCL[Default]}"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user