mechanicker icon

fastboot

mechanicker | PRO | 02/16/18 11:42:53 PM UTC | 0 ⭐ | 425 👁️ | Never ⏰ | []
Bash |

520 B

|

None

|

0 👍

/

0 👎

#!/usr/bin/env bash
# fool the flash-all.sh since it greps for dtbo.sig in fastboot binary: dtbo.sig
prog=$(basename $0)
realprog=${ANDROID_HOME}/platform-tools/${prog}
 
if [ ! -x ${realprog} ] ; then
    echo "error: failed to find ${realprog}"
    exit -1
fi
 
# Copy the args so that we can massage it
args="${EXTOPTS} $*"
 
# Skip reboot if fastboot
if [ ${prog} = fastboot ] ; then
    if [ x$NOWIPE != x ] ; then
        args=${args//-w /}
    fi
fi
 
# Invoke the real command
${ACTION} ${realprog} ${args}

Comments