From afb6bd984202c0f6a3ea22e1a08dc23c4cf5447e Mon Sep 17 00:00:00 2001 From: qnblackcat Date: Wed, 27 Apr 2022 12:45:26 +0700 Subject: [PATCH] update buildapp script --- Makefile | 2 +- buildapp.sh | 23 +++++++++++++++++------ 2 files changed, 18 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index e5a1ecc..6ebb194 100644 --- a/Makefile +++ b/Makefile @@ -11,7 +11,7 @@ DISPLAY_NAME = YouTube BUNDLE_ID = com.google.ios.youtube uYouPlus_FILES = uYouPlus.xm Settings.xm -uYouPlus_IPA = /path/to/your/decrypted/YouTube/IPA +uYouPlus_IPA = ./tmp/Payload/YouTube.app ### Important: edit the path to your decrypted YouTube IPA!!! include $(THEOS)/makefiles/common.mk diff --git a/buildapp.sh b/buildapp.sh index b838f75..1836313 100755 --- a/buildapp.sh +++ b/buildapp.sh @@ -22,16 +22,27 @@ else fi # Makefile - read -e -p "==> Path to the decrypted YouTube iPA: " PATHTOIPA - if [[ $PATHTOIPA == *.ipa ]] + read -e -p "==> Path to the decrypted YouTube.ipa or YouTube.app: " PATHTOYT +if [[ $PATHTOYT == *.ipa ]] then - sed -i '' "14s#.*#uYouPlus_IPA = $PATHTOIPA#g" ./Makefile + unzip -q "$PATHTOYT" -d ./tmp + (cd tmp/Payload/YouTube.app/PlugIns && rm -rf MessagesExtension.appex BroadcastUIExtension.appex BroadcastUploadExtension.appex) + cp -R Extensions/*.appex tmp/Payload/YouTube.app/PlugIns + make package + open ./packages + +elif [[ $PATHTOYT == *.app ]] +then + mkdir -p ./tmp/Payload/ + cp -R "$PATHTOYT" ./tmp/Payload 2>/dev/null + (cd tmp/Payload/YouTube.app/PlugIns && rm -rf MessagesExtension.appex BroadcastUIExtension.appex BroadcastUploadExtension.appex) + cp -R Extensions/*.appex tmp/Payload/YouTube.app/PlugIns make package open ./packages else - echo "This is not an iPA" - fi + echo "This is not an ipa/app!" +fi # Clean up tput setaf 1 && echo -e "==> \033[1mCleaning up...\033[0m" find Tweaks/uYou -mindepth 1 ! -name "com.miro.uyou_2.1_iphoneos-arm.deb" ! -name ".gitkeep" -exec rm -rf {} \; 2>/dev/null - rm -rf Resources .theos/_/Payload \ No newline at end of file + rm -rf tmp/ Resources .theos/_/Payload \ No newline at end of file