mirror of
https://github.com/msfjarvis/compose-lobsters
synced 2025-08-17 19:07:02 +05:30
scripts: add boot_emulator.sh
Signed-off-by: Harsh Shandilya <me@msfjarvis.dev>
This commit is contained in:
parent
3d7172d664
commit
a5a710cbb1
1 changed files with 22 additions and 0 deletions
22
scripts/boot_emulator.sh
Executable file
22
scripts/boot_emulator.sh
Executable file
|
@ -0,0 +1,22 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Creates and boots an emulator that exactly matches the one in our CI. It is recommended
|
||||||
|
# to use this as the target device for screenshot tests.
|
||||||
|
|
||||||
|
set -euxo pipefail
|
||||||
|
|
||||||
|
[ -n "${ANDROID_SDK_ROOT}" ] || { echo "ANDROID_SDK_ROOT must be set to use this script"; exit 1; }
|
||||||
|
|
||||||
|
"${ANDROID_SDK_ROOT}"/cmdline-tools/latest/bin/avdmanager create avd \
|
||||||
|
--force \
|
||||||
|
-n Pixel_XL_API_30 \
|
||||||
|
--abi 'google_apis/x86' \
|
||||||
|
--package 'system-images;android-30;google_apis;x86' \
|
||||||
|
--device 'pixel_xl'
|
||||||
|
"${ANDROID_SDK_ROOT}"/emulator/emulator \
|
||||||
|
-avd Pixel_XL_API_30 \
|
||||||
|
-no-window \
|
||||||
|
-gpu swiftshader_indirect \
|
||||||
|
-no-snapshot \
|
||||||
|
-noaudio \
|
||||||
|
-no-boot-anim
|
Loading…
Add table
Add a link
Reference in a new issue