Update run.sh

This commit is contained in:
2018-10-15 23:06:06 -05:00
parent fc954a78ad
commit 7a8c6aec7b

9
run.sh
View File

@@ -1,6 +1,8 @@
#!/usr/bin/env bash
# UbUpdate - Ubuntu Update Scripts Loader
source /opt/LinUPx/settings.conf
cd /opt/LinUPx
echo ""
@@ -9,10 +11,15 @@ if [ "`git log --pretty=%H ...refs/heads/master^ | head -n 1`" = "`git ls-remote
else
echo -e "\e[93m\e[1mnot up to date\e[21m, updating now...\e[0m"
sleep 1
# git -c http.sslVerify=false pull
git fetch origin master
git reset --hard origin/master
source /opt/LinUPx/settings.conf
git reflog expire --expire=now --all
git repack -ad # Remove dangling objects from packfiles
git prune # Remove dangling loose objects
echo ""
echo -e "\e[92m\e[1mLinUPx update completed\e[0m"
fi