Skip to content

Commit e5dc155

Browse files
committed
Upload file
1 parent c0c991e commit e5dc155

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

pio/src/main/assets/module/ZADD/patch_rom/patch-rom.bash

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
#!/data/data/com.tool.tree/files/home/bin/bash
22
# Kakathic
33
set -o pipefail
4-
IFS=$'\n'
54

65
fixapps(){
76
for vv in $@; do
@@ -37,6 +36,7 @@ elif [ "${vv##*/}" == "MIUIWeather.apk" ];then
3736
fi
3837
elif [[ "${vv##*/}" == *ThemeManager* ]];then
3938
if [ "$fix_themes" == 1 ];then
39+
IFS=$'\n'
4040
Tmtong="$(Timkiem '$onlineThemeDetail' $oi/smali)"
4141
if [ "$Tmtong" ]; then
4242
for vqq1 in $(grep 'Lcom/android/thememanager/detail/theme/model/OnlineResourceDetail;->bought:Z' $Tmtong); do
@@ -85,6 +85,12 @@ elif [[ "${vv##*/}" == *PersonalAssistant* ]];then
8585
fi
8686
# End patch smali
8787
apkeditor_b -i "$oi" -o "${vv%/*}" -d 1 -x false
88+
# di chuyển vào product app
89+
if [ "$(echo "$vv" | grep -cm1 "/data-app/")" == 1 ];then
90+
pproduct="$(ls -1d $SDH/$PTSH/*roduc*/etc/build.prop 2>/dev/null | grep -m1 'product' | sed 's|\/etc/build.prop||')"
91+
[ -z "$pproduct" ] && pproduct="$(ls -1d $SDH/$PTSH/*/*roduc*/etc/build.prop 2>/dev/null | grep -m1 'product' | sed 's|\/etc/build.prop||')"
92+
mv "${vv%/*}" "$pproduct/app"
93+
fi
8894
echo
8995
done
9096
}
@@ -306,6 +312,7 @@ elif [ "${vv##*/}" == "Settings.apk" ];then
306312
if [ "$(grep -cm1 device_description_cpu "$oi/resources/package_1/res/values/strings.xml")" != 1 ];then
307313
smurl1="$(find $oi/smali/classes*/com/android/settings/device/DeviceParamsInitHelper.smali -type f)"
308314
if [ -f "$smurl1" ];then
315+
IFS=$'\n'
309316
for vnl in $(grep -B 2 -n "langType" "$smurl1" | tac | grep 'move-result-object'); do
310317
sed -i "$(echo "$vnl" | cut -d- -f1)a\ const-string $(echo "$vnl" | awk '{print $3}'), \"enUS\"" "$smurl1"
311318
done

0 commit comments

Comments
 (0)