|
|
@@ -24,15 +24,18 @@ setup_auto_boot () {
|
|
|
echo "Success, launch Termux:boot once to activiate it."
|
|
|
}
|
|
|
copy_scripts () {
|
|
|
+ set -e
|
|
|
sed "s/AGENCY_ID/${1}/g" exec.sh.in > exec.sh
|
|
|
adb push exec.sh /sdcard/wechat/exec.sh
|
|
|
adb push crontab /sdcard/
|
|
|
adb push start.sh /sdcard/start.sh
|
|
|
adb push start_fg.sh /sdcard/crond.sh
|
|
|
+ set +e
|
|
|
adb shell "su - [ -d /data/data/com.termux/files/home ]"
|
|
|
if [ "$?" != "0" ]; then
|
|
|
read -p "Launch Termux for its bootstraping, press any key when completed"
|
|
|
fi
|
|
|
+ set -e
|
|
|
adb shell 'su - mv -f /sdcard/start.sh /data/data/com.termux/files/home/start.sh'
|
|
|
adb shell 'su - chmod 555 /data/data/com.termux/files/home/start.sh'
|
|
|
echo "Final step: install Busybox MANUALLY and execute ./start.sh in Termux at every time startup"
|