shell “syntax error near unexpected token ‘$‘\r‘‘” 错误解决方法
sed ‘s/\r//‘ test_freq.sh >aa.sh
function loop() { adb wait-for-device adb shell setenforce 0 adb shell chmod 777 /d/hisi_lpm3_debug/lpm3_test adb shell chmod 777 /d/hisi_lpm3_debug/cluster_freq adb shell chmod 777 /d/hisi_lpm3_debug/cluster_volt adb shell chmod 777 /sys/devices/system/cpu/cpu0/online adb shell chmod 777 /sys/devices/system/cpu/cpu1/online adb shell chmod 777 /sys/devices/system/cpu/cpu2/online adb shell chmod 777 /sys/devices/system/cpu/cpu3/online adb shell chmod 777 /sys/devices/system/cpu/cpu4/online adb shell chmod 777 /sys/devices/system/cpu/cpu5/online adb shell chmod 777 /sys/devices/system/cpu/cpu6/online adb shell chmod 777 /sys/devices/system/cpu/cpu7/online if [ 0 -eq $1 ] ; then adb shell am start -n com.hust.hoyihu/.MainActivity fi ping 127.0.0.1 -n 3 > null loop 1 } adb install Hoyihu_O.apk adb push test_video.mp4 /storage/sdcard0/ adb reboot bootloader fastboot oem watchdog ap enable fastboot getvar nve:[email protected]1111011111101010101111111010011000100110 fastboot oem boot adb wait-for-device root adb remount adb shell setenforce 0 ping 127.0.0.1 -n 14 > null loop 0