mirror of
https://github.com/FiorenMas/Revanced-And-Revanced-Extended-Non-Root.git
synced 2025-12-06 16:17:40 +00:00
Update utils.sh
This commit is contained in:
@@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
#################################################
|
#################################################
|
||||||
|
|
||||||
|
# Download Github assets requirement:
|
||||||
dl_gh() {
|
dl_gh() {
|
||||||
for repo in $1 ; do
|
for repo in $1 ; do
|
||||||
wget -qO- "https://api.github.com/repos/$2/$repo/releases/$3" \
|
wget -qO- "https://api.github.com/repos/$2/$repo/releases/$3" \
|
||||||
@@ -16,6 +17,7 @@ echo "All assets downloaded"
|
|||||||
|
|
||||||
#################################################
|
#################################################
|
||||||
|
|
||||||
|
# Get patches list:
|
||||||
get_patches_key() {
|
get_patches_key() {
|
||||||
EXCLUDE_PATCHES=()
|
EXCLUDE_PATCHES=()
|
||||||
for word in $(cat src/patches/$1/exclude-patches) ; do
|
for word in $(cat src/patches/$1/exclude-patches) ; do
|
||||||
@@ -29,6 +31,7 @@ get_patches_key() {
|
|||||||
|
|
||||||
#################################################
|
#################################################
|
||||||
|
|
||||||
|
# Find version supported:
|
||||||
get_ver() {
|
get_ver() {
|
||||||
version=$(jq -r --arg patch_name "$1" --arg pkg_name "$2" '
|
version=$(jq -r --arg patch_name "$1" --arg pkg_name "$2" '
|
||||||
.[]
|
.[]
|
||||||
@@ -41,6 +44,7 @@ get_ver() {
|
|||||||
|
|
||||||
#################################################
|
#################################################
|
||||||
|
|
||||||
|
# Download apks files from APKMirror:
|
||||||
req() {
|
req() {
|
||||||
wget -nv -O "$2" -U "Mozilla/5.0 (X11; Linux x86_64; rv:111.0) Gecko/20100101 Firefox/111.0" "$1"
|
wget -nv -O "$2" -U "Mozilla/5.0 (X11; Linux x86_64; rv:111.0) Gecko/20100101 Firefox/111.0" "$1"
|
||||||
}
|
}
|
||||||
@@ -90,6 +94,7 @@ get_apk() {
|
|||||||
|
|
||||||
#################################################
|
#################################################
|
||||||
|
|
||||||
|
# Patching apps with Revanced CLI:
|
||||||
patch() {
|
patch() {
|
||||||
if [ -f "$1.apk" ]; then
|
if [ -f "$1.apk" ]; then
|
||||||
java -jar revanced-cli*.jar \
|
java -jar revanced-cli*.jar \
|
||||||
@@ -110,6 +115,7 @@ patch() {
|
|||||||
|
|
||||||
#################################################
|
#################################################
|
||||||
|
|
||||||
|
# Split architectures using Revanced CLI, created by j-hc:
|
||||||
archs=("arm64-v8a" "armeabi-v7a" "x86_64" "x86")
|
archs=("arm64-v8a" "armeabi-v7a" "x86_64" "x86")
|
||||||
libs=("x86_64 x86 armeabi-v7a" "x86_64 x86 arm64-v8a" "x86 armeabi-v7a arm64-v8a" "x86_64 armeabi-v7a arm64-v8a")
|
libs=("x86_64 x86 armeabi-v7a" "x86_64 x86 arm64-v8a" "x86 armeabi-v7a arm64-v8a" "x86_64 armeabi-v7a arm64-v8a")
|
||||||
gen_rip_libs() {
|
gen_rip_libs() {
|
||||||
@@ -130,4 +136,4 @@ split_arch() {
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
#################################################
|
#################################################
|
||||||
|
|||||||
Reference in New Issue
Block a user