6

90+% of the time, I open Android Studio just to open AVD, then I close Android Studio. Is there a way to open AVD or emulators directly? I'm using Windows 10.

I tried the avdmanager command, but there doesn't seem to be a way to open an emulator using it.

I can't find an exe to open the AVD manager directly.

fixer1234
  • 27,486
Leo Jiang
  • 976

4 Answers4

4

I had the same question today, and I found this nice gist:

https://gist.github.com/hidroh/67b2ee7bbdd9038450c00d8a4d69c3fa

Notes:

  • Added the Android SDK tools/ directory to my PATH.
  • Downloaded the gist above onto my desktop to a file called avd.sh.
  • Since I have Git for Windows installed, the .sh file opens in Git Bash automatically when I double click it.
  • It should find all the emulators you setup in AVD and give you an option to choose which one. Type in the number, and the emulator will launch!

Hope this helps!

  • I'm still curious if it's possible to launch the AVD manager itself without going into Android Studio, so if anyone figures it out let me know. – Jesse Zamora Mar 09 '17 at 17:40
  • 1
    Can you clarify what the gist of that gist is? If the link disappears, what should OP do? – bertieb Mar 16 '17 at 01:16
2

This is what I did:

-I've installed git
-run git bash
-go to this directory Android/sdk/tools/bin (hope you know how to use cd command)
-emulator -list-avds (to get the list of avds)
-emulator -netdelay none -netspeed full -avd Nexus_7_API_23

Nexus_7_API_23 is one of the emulators I made before inside android studio. You select one of yours that you got on your list.

Eftekhari
  • 401
  • 2
  • 5
  • 11
1

Create a run-emulator.sh file with:

pushd ${ANDROID_HOME}/emulator
./emulator -list-avds | cat -n
printf "Select AVD: "
read index
avd=$(./emulator -list-avds | sed "${index}q;d")
echo "Selected $avd"
./emulator -netdelay none -netspeed full -avd $avd
popd

Give run permissions to file with chmod +x run-emulator.sh

Call ./run-emulator.sh

It will show you a menu with options to quick start any virtual image.

0

In Ubuntu 19.10!

With the environment variables already configured ($ANDROID_HOME), you should be able to list the AVDs, but if you are unable to start the AVD, do the following:

# Check the AVD target name

emulator -list-avds

# But to start do:

$ANDROID_HOME/emulator/emulator @avd_name

or

/home/$USER/Android/Sdk/emulator/emulator @avd_name