Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update Travis CI configuration as an old one doesn't work anymore (pr…
…ocess crashes)
- Loading branch information
Showing
3 changed files
with
133 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#!/bin/bash | ||
|
||
# Originally written by Ralf Kistner <ralf@embarkmobile.com>, but placed in the public domain | ||
|
||
set +e | ||
|
||
bootanim="" | ||
failcounter=0 | ||
timeout_in_sec=600 # 10 minutes | ||
|
||
until [[ "$bootanim" =~ "stopped" ]]; do | ||
bootanim=`adb -e shell getprop init.svc.bootanim 2>&1 &` | ||
if [[ "$bootanim" =~ "device not found" || "$bootanim" =~ "device offline" | ||
|| "$bootanim" =~ "running" || "$bootanim" =~ "error: no emulators found" ]]; then | ||
let "failcounter += 1" | ||
echo "Waiting for emulator to start" | ||
if [[ $failcounter -gt timeout_in_sec ]]; then | ||
echo "Timeout ($timeout_in_sec seconds) reached; failed to start emulator" | ||
exit 1 | ||
fi | ||
fi | ||
sleep 1 | ||
done | ||
|
||
echo "Emulator is ready" | ||
|