diff --git a/Apps/rclone/setup-rclone-termux.bash b/Apps/rclone/setup-rclone-termux.bash index 94c65b3..ad71fde 100644 --- a/Apps/rclone/setup-rclone-termux.bash +++ b/Apps/rclone/setup-rclone-termux.bash @@ -1,8 +1,19 @@ #!/bin/bash RCLONE_PATH="./.rclone-files/" - ARCH=$(uname -m) +RCLONE_URL="" +FUSERMOUNT_URL="" +if [ "$ARCH" == "armv7l" ];then + RCLONE_URL="https://beta.rclone.org/test/testbuilds-latest/rclone-android-16-armv7a.gz" + FUSERMOUNT_URL="https://github.com/Magisk-Modules-Repo/com.piyushgarg.rclone/raw/master/binary/fusermount-arm" +elif [ "$ARCH" == "aarch64" ];then + RCLONE_URL="https://beta.rclone.org/test/testbuilds-latest/rclone-android-21-armv8a.gz" + FUSERMOUNT_URL="https://github.com/Magisk-Modules-Repo/com.piyushgarg.rclone/raw/master/binary/fusermount-arm64" +else + echo "Unsupported architecture: $ARCH" + exit 1 +fi echo "!!! YOU NEED ROOT TO RUN THIS SCRIPT !!!" echo "Installing dependencies..." @@ -11,18 +22,7 @@ echo "Setting up Termux shared storage..." termux-setup-storage echo "Downloading rclone..." mkdir -p $RCLONE_PATH -RCLONE_URL="" -FUSERMOUNT_URL="" -if [ "$ARCH" == "armv7l" ];then - $RCLONE_URL="https://beta.rclone.org/test/testbuilds-latest/rclone-android-16-armv7a.gz" - $FUSERMOUNT_URL="https://github.com/Magisk-Modules-Repo/com.piyushgarg.rclone/raw/master/binary/fusermount-arm" -elif [ "$ARCH" == "aarch64" ];then - $RCLONE_URL="https://beta.rclone.org/test/testbuilds-latest/rclone-android-21-armv8a.gz" - $FUSERMOUNT_URL="https://github.com/Magisk-Modules-Repo/com.piyushgarg.rclone/raw/master/binary/fusermount-arm64" -else - echo "Unsupported architecture: $ARCH" - exit 1 -fi + echo "Downloading rclone..." wget -O - $RCLONE_URL | gunzip -c > "$RCLONE_PATH/rclone" echo "Downloading fusermount..."