Add adb_wait_for_device script
BUG=skia:3718 Review URL: https://codereview.chromium.org/1149163003
This commit is contained in:
parent
d26c9fa66c
commit
5aa5ea3831
16
platform_tools/android/bin/adb_wait_for_device
Executable file
16
platform_tools/android/bin/adb_wait_for_device
Executable file
@ -0,0 +1,16 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Wait for the device to be both attached and booted.
|
||||
|
||||
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
source $SCRIPT_DIR/android_setup.sh
|
||||
source $SCRIPT_DIR/utils/setup_adb.sh
|
||||
|
||||
set -e
|
||||
set -x
|
||||
|
||||
$ADB $DEVICE_SERIAL wait-for-device
|
||||
|
||||
while [ "$($ADB $DEVICE_SERIAL shell getprop sys.boot_completed | tr -d '\r')" != "1" ]; do
|
||||
sleep 5
|
||||
done
|
Loading…
Reference in New Issue
Block a user