@@ -9,7 +9,7 @@ MODDIR="$MODDIR"
9
9
MODDIR_NAME=" ${MODDIR##*/ } "
10
10
tools_path=" $MODDIR /tools"
11
11
script=" ${0##*/ } "
12
- backup_version=" 202504241535 "
12
+ backup_version=" 202504260051 "
13
13
[[ $SHELL = * mt* ]] && echo " 請勿使用MT管理器拓展包環境執行,請更換系統環境" && exit 2
14
14
update_backup_settings_conf () {
15
15
echo " #0關閉音量鍵選擇 (如選項未設置,則強制使用音量鍵選擇)
@@ -254,6 +254,7 @@ arm64*)
254
254
exit 1
255
255
;;
256
256
esac
257
+ get_mv=" $( which mv) "
257
258
PATH=" /data/adb/ksu/bin:/sbin/.magisk/busybox:/sbin/.magisk:/sbin:/data/adb/ksu/bin:/system_ext/bin:/system/bin:/system/xbin:/vendor/bin:/vendor/xbin:/data/data/com.omarea.vtools/files/toolkit:/data/user/0/com.termux/files/usr/bin"
258
259
if [[ -d $( magisk --path 2> /dev/null) ]]; then
259
260
PATH=" $( magisk --path 2> /dev/null) /.magisk/busybox:$PATH "
@@ -374,6 +375,7 @@ case $LANG in
374
375
alias ts=" app_process /system/bin com.xayah.dex.CCUtil s2t $@ " ;;
375
376
esac
376
377
alias LS=" toybox ls -Zd"
378
+ alias mv=" $get_mv "
377
379
Set_back_0 () {
378
380
return 0
379
381
}
@@ -757,6 +759,7 @@ update_script() {
757
759
echoRgb " 從$zipFile 更新"
758
760
if [[ -d $path_hierarchy /tools ]]; then
759
761
mv " $path_hierarchy /tools" " $TMPDIR "
762
+ [[ -d $TMPDIR /tools ]] && {
760
763
unzip -o " $zipFile " tools/* -d " $path_hierarchy " | sed ' s/inflating/釋放/g ; s/creating/創建/g ; s/Archive/解壓縮/g'
761
764
echo_log " 解壓縮${zipFile##*/ } "
762
765
if [[ $result = 0 ]]; then
@@ -796,6 +799,7 @@ update_script() {
796
799
rm -rf " $TMPDIR " /* " $zipFile " " $MODDIR /tools.sh"
797
800
echoRgb " 更新完成 請重新執行腳本" " 2"
798
801
exit
802
+ } || echoRgb " tools移動到TMPDIR失敗" " 0"
799
803
fi
800
804
else
801
805
echoRgb " ${zipFile##*/ } 版本低於當前版本,自動刪除" " 0"
@@ -907,7 +911,7 @@ if [[ $json != "" ]]; then
907
911
download=" $( jq -r ' .assets[].browser_download_url' <<< " $json" ) "
908
912
case $cdn in
909
913
1) zip_url=" http://huge.cf/download/?huge-url=$download " ;;
910
- 2) zip_url=" https://mirror.ghproxy.com /$download " ;;
914
+ 2) zip_url=" https://github.moeyy.xyz /$download " ;;
911
915
3) zip_url=" https://gh.api.99988866.xyz/$download " ;;
912
916
4) zip_url=" https://github.lx164.workers.dev/$download " ;;
913
917
5) zip_url=" https://shrill-pond-3e81.hunsh.workers.dev/$download " ;;
@@ -1234,12 +1238,10 @@ Backup_data() {
1234
1238
esac
1235
1239
;;
1236
1240
* )
1237
- if [[ $ksu = " " ]]; then
1238
- case $Compression_method in
1239
- tar | Tar | TAR) tar --checkpoint-action=" ttyout=%T\r" --exclude=" Backup_" * --exclude=" ${data_path##*/ } /cache" --exclude=" ${data_path##*/ } /QQ" --exclude=" ${data_path##*/ } /Telegram" --exclude=" ${data_path##*/ } " /.* --warning=no-file-changed -cpf " $Backup_folder /$1 .tar" -C " ${data_path%/* } " " ${data_path##*/ } " ;;
1240
- zstd | Zstd | ZSTD) tar --checkpoint-action=" ttyout=%T\r" --exclude=" Backup_" * --exclude=" ${data_path##*/ } /cache" --exclude=" ${data_path##*/ } /QQ" --exclude=" ${data_path##*/ } /Telegram" --exclude=" ${data_path##*/ } " /.* --warning=no-file-changed -cpf - -C " ${data_path%/* } " " ${data_path##*/ } " | zstd --ultra -3 -T0 -q --priority=rt > " $Backup_folder /$1 .tar.zst" ;;
1241
- esac
1242
- fi
1241
+ case $Compression_method in
1242
+ tar | Tar | TAR) tar --checkpoint-action=" ttyout=%T\r" --exclude=" Backup_" * --exclude=" ${data_path##*/ } /cache" --exclude=" ${data_path##*/ } /QQ" --exclude=" ${data_path##*/ } /Telegram" --exclude=" ${data_path##*/ } " /.* --warning=no-file-changed -cpf " $Backup_folder /$1 .tar" -C " ${data_path%/* } " " ${data_path##*/ } " ;;
1243
+ zstd | Zstd | ZSTD) tar --checkpoint-action=" ttyout=%T\r" --exclude=" Backup_" * --exclude=" ${data_path##*/ } /cache" --exclude=" ${data_path##*/ } /QQ" --exclude=" ${data_path##*/ } /Telegram" --exclude=" ${data_path##*/ } " /.* --warning=no-file-changed -cpf - -C " ${data_path%/* } " " ${data_path##*/ } " | zstd --ultra -3 -T0 -q --priority=rt > " $Backup_folder /$1 .tar.zst" ;;
1244
+ esac
1243
1245
;;
1244
1246
esac
1245
1247
echo_log " 備份$1 數據"
@@ -2624,7 +2626,7 @@ Getlist)
2624
2626
if [[ $( cat " $nametxt " | cut -f2 -d ' ' | egrep -w " ^${app_1[1]} $" ) != ${app_1[1]} ]]; then
2625
2627
[[ $REPLY2 = " " ]] && add_entry " ${app_1[2]} " " ${app_1[1]} " " $( cat " $nametxt " | grep -w " ${app_1[2]} " ) " || add_entry " ${app_1[2]} " " ${app_1[1]} " " $REPLY2 "
2626
2628
case ${app_1[1]} in
2627
- * oneplus* |* miui* |* xiaomi* |* oppo* |* flyme* |* meizu* |com.android.soundrecorder|com.mfashiongallery.emag|com.mi.health|* coloros* |com.android.soundrecorder|com.duokan.phone.remotecontroller|com.android.calendar|com.android.deskclock|com.android.calendar|com.android.deskclock)
2629
+ * oneplus* |* miui* |* xiaomi* |* oppo* |* flyme* |* meizu* |com.android.soundrecorder|com.mfashiongallery.emag|com.mi.health|* coloros* |com.android.soundrecorder|com.duokan.phone.remotecontroller|com.android.calendar|com.android.deskclock|com.android.calendar|com.android.deskclock|com.google.android.safetycore|com.google.android.contactkeys )
2628
2630
if [[ $( echo " $xposed_name " | egrep -w " ${app_1[1]} $" ) = ${app_1[1]} ]]; then
2629
2631
echoRgb " $app_name 為Xposed模塊 進行添加" " 0"
2630
2632
if [[ $REPLY2 = " " ]]; then
0 commit comments