From aaa98910e6e278d7409f27312ed33401a4f2ca10 Mon Sep 17 00:00:00 2001 From: Sushrut1101 Date: Sat, 14 May 2022 01:11:18 +0530 Subject: [PATCH] Fix Latest Magisk Release Signed-off-by: Sushrut1101 --- scripts/build.sh | 2 +- scripts/sync.sh | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/build.sh b/scripts/build.sh index 5cd22ade..f197823d 100644 --- a/scripts/build.sh +++ b/scripts/build.sh @@ -75,7 +75,7 @@ BRANCH_INT=$(echo $SYNC_BRANCH | cut -d. -f1) # Magisk if [[ $OF_USE_LATEST_MAGISK = "true" || $OF_USE_LATEST_MAGISK = "1" ]]; then echo "Using the Latest Release of Magisk..." - export FOX_USE_SPECIFIC_MAGISK_ZIP="~/Magisk/$(ls ~/Magisk/Magisk*.zip)" + export FOX_USE_SPECIFIC_MAGISK_ZIP=$("ls" ~/Magisk/Magisk*.zip) fi # Legacy Build Systems diff --git a/scripts/sync.sh b/scripts/sync.sh index ca0a08a4..6eb870d4 100644 --- a/scripts/sync.sh +++ b/scripts/sync.sh @@ -64,7 +64,8 @@ if [[ $OF_USE_LATEST_MAGISK = "true" || $OF_USE_LATEST_MAGISK = "1" ]]; then aria2c $LATEST_MAGISK_URL 2>&1 || wget $LATEST_MAGISK_URL 2>&1 echo "Magisk Downloaded Successfully" echo "Renaming .apk to .zip ..." - rename 's/.apk/.zip/' Magisk* + #rename 's/.apk/.zip/' Magisk* + mv $("ls" Magisk*.apk) $("ls" Magisk*.apk | sed 's/.apk/.zip/g') cd $SYNC_PATH >/dev/null echo "Done!" fi