This commit is contained in:
2024-02-10 15:23:38 -06:00
parent 3ba33081af
commit f8045fa26b
2 changed files with 22 additions and 23 deletions

View File

@@ -2,7 +2,7 @@
action="$1"
FOLDER='/opt/idssys/linupx'
VERS='6.60.24-02102024'
VERS='6.60.25-02102024'
IPERFVER="3.15"

43
run.sh
View File

@@ -23,7 +23,7 @@ if curl -m 3 -s --head --request GET https://git.schroedercity.com | grep "HTTP
if [ "`git log --pretty=%H ...refs/heads/master^ | head -n 1`" != "`git ls-remote origin -h refs/heads/master |cut -f1`" ]; then
if [ "${1}" != "runup" ]; then
echo -en "\e[1A";
echo -e "${idsCL[LightCyan]}Updating iDSSYS-Defaults...${idsCL[Default]}"
echo -en "${idsCL[LightCyan]}Updating iDSSYS-Defaults...${idsCL[Default]}"
udtd=true
fi
git fetch origin master >/dev/null 2>&1
@@ -32,6 +32,7 @@ if curl -m 3 -s --head --request GET https://git.schroedercity.com | grep "HTTP
git repack -ad >/dev/null 2>&1
git prune >/dev/null 2>&1
git pull >/dev/null 2>&1
[ "${1}" != "runup" ] && echo -e "${idsCL[Green]}Done${idsCL[Default]}"
fi
fi
fi
@@ -40,33 +41,31 @@ if curl -m 3 -s --head --request GET https://git.schroedercity.com | grep "HTTP
else
cd /opt/idssys/linupx
fi
if [ "$1" != "update" ] && [ "$1" != "up" ]; then
if [ "`git log --pretty=%H ...refs/heads/master^ | head -n 1`" != "`git ls-remote origin -h refs/heads/master |cut -f1`" ]; then
if [ "${1}" != "runup" ]; then
echo -en "\e[1A";
echo -e "\e[0K\r ${idsCL[LightCyan]}Updating LinUPx...${idsCL[Default]}"
udtd=true
fi
git fetch origin master >/dev/null 2>&1
git reset --hard origin/master >/dev/null 2>&1
git reflog expire --expire=now --all >/dev/null 2>&1
git repack -ad >/dev/null 2>&1
git prune >/dev/null 2>&1
git pull >/dev/null 2>&1
if [ "${1}" != "runup" ]; then
source /opt/idssys/linupx/defaults.inc
echo -en "\e[1A";
echo -e "\e[0K\r ${idsCL[Green]}Updated to v${VERS}${idsCL[Default]}"
fi
if [ "`git log --pretty=%H ...refs/heads/master^ | head -n 1`" != "`git ls-remote origin -h refs/heads/master |cut -f1`" ]; then
if [ "${1}" != "runup" ]; then
echo -en "${idsCL[LightCyan]}Updating LinUPx...${idsCL[Default]}"
udtd=true
fi
fi
if [ "${1}" != "runup" ] && [ "${udtd}" == "false" ]; then
git fetch origin master >/dev/null 2>&1
git reset --hard origin/master >/dev/null 2>&1
git reflog expire --expire=now --all >/dev/null 2>&1
git repack -ad >/dev/null 2>&1
git prune >/dev/null 2>&1
git pull >/dev/null 2>&1
if [ "${1}" != "runup" ]; then
source /opt/idssys/linupx/defaults.inc
# echo -en "\e[1A";
# echo -e "\e[0K\r ${idsCL[Green]}Updated to v${VERS}${idsCL[Default]}"
echo -e "${idsCL[Green]}Updated to v${VERS}${idsCL[Default]}"
fi
elif [ "${1}" != "runup" ]; then
echo -en "\e[1A";
echo -e "\e[0K\r ${idsCL[Green]}No updates available${idsCL[Default]}"
echo ""
fi
else
echo -e "${idsCL[Red]}Could not connect to 'git.schroedercity.com' for updates${idsCL[Default]}"
fi