-
Notifications
You must be signed in to change notification settings - Fork 0
/
script_android
48 lines (36 loc) · 1.65 KB
/
script_android
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
echo "*---* VonDroid.com RK device Root Tool based on work by sunnydavid *---*"
echo "--- Plug in your device, make sure debugging is enabled in Developer Options"
echo "--- This script will now copy files over to your RK device"
adb shell mv /data/local/tmp /data/local/tmp.bak
adb shell ln -s /data /data/local/tmp
adb reboot
echo "--- Reboot 1/3 - Press Space Bar once the device has rebooted"
read -p "or CTRL-C to exit"
adb shell rm /data/local.prop > nul
adb shell "echo \"ro.kernel.qemu=1\" > /data/local.prop"
adb reboot
echo "--- Reboot 2/3 - Press Space Bar once the device has rebooted"
read -p "or CTRL-C to exit"
adb shell id
echo "--- If the ID shows as 0(root) then continue, otherwise CTRL+C to cancel and start over"
read -p "CTRL-C to exit"
adb remount
adb push su /system/bin/su
adb shell chown root.shell /system/bin/su
adb shell chmod 6755 /system/bin/su
adb push busybox /system/bin/busybox
adb shell chown root.shell /system/bin/busybox
adb shell chmod 0755 /system/bin/busybox
echo "--- Installing SuperSU"
adb push SuperSU.apk /system/app/SuperSU.apk
adb shell chown root.root /system/app/SuperSU.apk
adb shell chmod 0644 /system/app/SuperSU.apk
adb push RootExplorer.apk /system/app/RootExplorer.apk
adb shell chown root.root /system/app/RootExplorer.apk
adb shell chmod 0644 /system/app/RootExplorer.apk
echo "Completing Root ..."
adb shell rm /data/local.prop
adb shell rm /data/local/tmp
adb shell mv /data/local/tmp.bak /data/local/tmp
adb reboot
echo "--- Reboot 3/3 - Your RK device should now be rooted!"