@@ -4,70 +4,96 @@ path_modun="/data/adb/modules/Tool-Tree"
44path_modun2=" /data/adb/modules_update/Tool-Tree"
55
66home () {
7- # Đoạn code chính
8- echo ' <group title="' $google_text ' ">
9- <action warn="' $lang_action_warn ' ">
10- <title>' $lang_title ' </title>
11- <summary>' $lang_summary_path ' ' $path_modun ' </summary>
12- <param name="uri_file_modun" value-sh="glog uri_file_modun" options-sh="findfile files $PTAD" required="required" label="@string/options_text" multiple="true"/>
13- <param name="uri_adb_moduls" desc="' $lang_desc_adb ' " placeholder="/system_ext/priv-app/Settings/Settings.apk" value-sh="glog uri_adb_moduls" type="text" />
14- <set>
15- slog uri_adb_moduls "$uri_adb_moduls"
16- slog uri_file_modun "$uri_file_modun"
17- [ -f ' $path_modun ' /remove ] && rm -fr ' $path_modun ' /remove
18- mkdir -p ' $path_modun ' ' $path_modun2 '
19- for vcc in $uri_file_modun; do
20- if [ "$uri_adb_moduls" ]; then
21- mkdir -p "' $path_modun2 ' ${uri_adb_moduls%/*}"
22- cp -rf "$PTAD/$vcc" "' $path_modun2 ' $uri_adb_moduls"
23- echo "' $lang_save_at ' ' $path_modun2 ' $uri_adb_moduls"
24- echo
25- else
26- echo "' $lang_searching ' "
27- echo
28- link_find_file="$(find -L /system -name "$vcc" -type f -print -quit)"
29- if [ "$link_find_file" ]; then
30- mkdir -p "' $path_modun2 ' ${link_find_file%/*}"
31- cp -rf "$PTAD/$vcc" "' $path_modun2 ' $link_find_file"
32- echo "' $lang_save_at ' ' $path_modun2 ' $link_find_file"
33- echo
34- else
35- echo "' $lang_not_found ' \$vcc' $lang_input_notice ' "
36- fi
37- fi
38- done
39- echo "id=Tool-Tree
40- name=Tool-Tree Module
41- version=1.0
42- versionCode=100
43- author=Kakathic
44- description=Modified system files" | tee ' $path_modun ' /module.prop
45- chmod 644 ' $path_modun ' /module.prop ' $path_modun2 ' /system.prop
46- touch ' $path_modun ' /update
47- set_permis -R -o 0:0 -c u:object_r:system_file:s0 ' $path_modun2 ' /system
48- </set>
49- </action>
50- </group>
7+ echo ' [[group]]
8+ title = "' $google_text ' "
519
52- <group>
53- <editor title="' $lang_desc_prop ' " file="' $path_modun ' /system.prop" placeholder="ro.control_privapp_permissions=log"/>
54- </group>
10+ [[group.action]]
11+ warn = "' $lang_action_warn ' "
12+ title = "' $lang_title ' "
13+ summary = "' $lang_summary_path ' ' $path_modun ' "
14+ script = """
15+ slog uri_adb_moduls "$uri_adb_moduls"
16+ slog uri_file_modun "$uri_file_modun"
17+ [ -f ' $path_modun ' /remove ] && rm -fr ' $path_modun ' /remove
18+ mkdir -p ' $path_modun ' ' $path_modun2 '
19+ for vcc in $uri_file_modun; do
20+ if [ "$uri_adb_moduls" ]; then
21+ mkdir -p "' $path_modun2 ' ${uri_adb_moduls%/*}"
22+ cp -rf "$PTAD/$vcc" "' $path_modun2 ' $uri_adb_moduls"
23+ echo "' $lang_save_at ' ' $path_modun2 ' $uri_adb_moduls"
24+ echo
25+ else
26+ echo "' $lang_searching ' "
27+ echo
28+ link_find_file="$(find -L /system -name "$vcc" -type f -print -quit)"
29+ if [ "$link_find_file" ]; then
30+ mkdir -p "' $path_modun2 ' ${link_find_file%/*}"
31+ cp -rf "$PTAD/$vcc" "' $path_modun2 ' $link_find_file"
32+ echo "' $lang_save_at ' ' $path_modun2 ' $link_find_file"
33+ echo
34+ else
35+ echo "' $lang_not_found ' \\$vcc' $lang_input_notice ' "
36+ fi
37+ fi
38+ done
39+ echo "id=Tool-Tree
40+ name=Tool-Tree Module
41+ version=1.0
42+ versionCode=100
43+ author=Kakathic
44+ description=Modified system files" | tee ' $path_modun ' /module.prop
45+ chmod 644 ' $path_modun ' /module.prop ' $path_modun2 ' /system.prop
46+ touch ' $path_modun ' /update
47+ set_permis -R -o 0:0 -c u:object_r:system_file:s0 ' $path_modun2 ' /system
48+ """
5549
56- <group>
57- <action>
58- <title>' $lang_del_tile ' </title>
59- <desc>' $lang_del_desc ' </desc>
60- <param name="del_file_modun" desc="' $lang_del_desc2 ' ' $path_modun2 ' " value-sh="glog del_file_modun" label="@string/options_text" options-sh="[ -d ' $path_modun2 ' ] && find ' $path_modun2 ' /system -type f -printf ' " '%p|%f\n'" ' " required="required" multiple="true"/>
61- <set>
62- for vcx in $del_file_modun; do
63- echo "Delete file: $vcx"
64- [ -f "$vcx" ] && rm -fr "$vcx"
65- done
66- </set>
67- </action>
68- </group>
50+ [[group.action.params]]
51+ name = "uri_file_modun"
52+ value-sh = "glog uri_file_modun"
53+ options-sh = "findfile files $PTAD"
54+ required = "required"
55+ label = "@string/options_text"
56+ multiple = "true"
6957
70- <text desc="' $list_modul ' " summary-sh="find ' $path_modun ' -type f" />'
58+ [[group.action.params]]
59+ name = "uri_adb_moduls"
60+ desc = "' $lang_desc_adb ' "
61+ placeholder = "/system_ext/priv-app/Settings/Settings.apk"
62+ value-sh = "glog uri_adb_moduls"
63+ type = "text"
64+
65+ [[group]]
66+
67+ [[group.editor]]
68+ title = "' $lang_desc_prop ' "
69+ file = "' $path_modun ' /system.prop"
70+ placeholder = "ro.control_privapp_permissions=log"
71+
72+ [[group]]
73+
74+ [[group.action]]
75+ title = "' $lang_del_tile ' "
76+ desc = "' $lang_del_desc ' "
77+ script = """
78+ for vcx in $del_file_modun; do
79+ echo "Delete file: $vcx"
80+ [ -f "$vcx" ] && rm -fr "$vcx"
81+ done
82+ """
83+
84+ [[group.action.params]]
85+ name = "del_file_modun"
86+ desc = "' $lang_del_desc2 ' ' $path_modun2 ' "
87+ value-sh = "glog del_file_modun"
88+ label = "@string/options_text"
89+ options-sh = "[ -d ' $path_modun2 ' ] && find ' $path_modun2 ' /system -type f -printf ' " '%p|%f\\ n'" ' "
90+ required = "required"
91+ multiple = "true"
92+
93+ [[text]]
94+ desc = "' $list_modul ' "
95+ summary-sh = "find ' $path_modun ' -type f"
96+ '
7197}
7298
7399# Thư mục hiện tại
@@ -84,13 +110,4 @@ if [ "$(glog "auto_trans_text_${MPAT##*/}")" == 1 ]; then
84110fi
85111
86112# index
87- echo ' <?xml version="1.0" encoding="UTF-8" ?>
88- <group>'
89-
90- if [ " $( type -t " $1 " ) " = " function" ]; then
91- " $@ "
92- else
93- cat " $ETC /error.xml"
94- fi
95-
96- echo ' </group>'
113+ " $@ "
0 commit comments