Created
November 8, 2021 13:54
-
-
Save mdrokz/44f0bb9a06c6ca1057a8abde0b3e37d4 to your computer and use it in GitHub Desktop.
FIsh function to start android emulator from terminal.
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
# Usage - start_emulator Pixel 5 | |
function start_emulator | |
set emulator_list (~/Android/Sdk/emulator/emulator -list-avds) | |
for emulator in $emulator_list | |
set emulator_name (string split _ $emulator -f 1) | |
set emulator_version (string split _ $emulator -f 2) | |
if test $argv[1] = $emulator_name; and test $argv[2] = $emulator_version | |
~/Android/Sdk/emulator/emulator -avd $emulator | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment