Correct system-update so it isn't expecting static partitions.

This commit is contained in:
fewtarius 2022-03-22 16:07:23 -04:00
parent 42338a48e4
commit c2005a6bfe
No known key found for this signature in database
GPG key ID: F4AE55305D1B8C1A

View file

@ -48,6 +48,8 @@ ONLINE_STATUS=$(check_network)
if [ ! "${ONLINE_STATUS}" == true ] if [ ! "${ONLINE_STATUS}" == true ]
then then
echo "System not online, cannot continue..." >/dev/console echo "System not online, cannot continue..." >/dev/console
sleep 3
systemctl start emustation &
exit 0 exit 0
fi fi
@ -55,14 +57,15 @@ echo -e "=> ${OS_NAME} UPGRADE UTILITY" >/dev/console
# Check storage # Check storage
check_space size mmcblk0p1 boot 2048000 check_space size flash boot 2048000
check_space available mmcblk0p2 GAMES 3072000 check_space available .update GAMES 3072000
# Download # Download
LATEST_RELEASE_TAG=$(curl -H 'Cache-Control: no-cache' -Ls "${GIT_API}/releases" | python -c "import sys, json; print(json.load(sys.stdin)[0]['tag_name'])") LATEST_RELEASE_TAG=$(curl -H 'Cache-Control: no-cache' -Ls "${GIT_API}/releases" | python -c "import sys, json; print(json.load(sys.stdin)[0]['tag_name'])")
if [ "${OS_VERSION}" -ge "${LATEST_RELEASE_TAG}" ] if [ "${OS_VERSION}" -ge "${LATEST_RELEASE_TAG}" ]
then then
echo "No new updates are available..." >/dev/console echo "No new updates are available..." >/dev/console
sleep 3
systemctl start emustation & systemctl start emustation &
exit 0 exit 0
fi fi
@ -81,7 +84,7 @@ if [ ! "${MYSUM}" == "${DLSUM}" ]
then then
echo "Verification failed, cleaning up and exiting..." >/dev/console echo "Verification failed, cleaning up and exiting..." >/dev/console
rm -f ${UPDATE_PATH}/* rm -f ${UPDATE_PATH}/*
sleep 4 sleep 3
clear >/dev/console clear >/dev/console
systemctl start emustation systemctl start emustation
exit 1 exit 1
@ -91,4 +94,5 @@ fi
echo -e "\nRebooting to complete OS upgrade..." >/dev/console echo -e "\nRebooting to complete OS upgrade..." >/dev/console
sync sync
sleep 3
reboot reboot