- Find the location of the Android SDK
- File -> New Projects Setup -> Default Project structure
- Copy the address in the section of Android SDK location
- set up
adb
- Input
adb
, ifadb: command not found
, you have to set up. - Open the terminal
- Input
echo $HOME
- Create
.bash_profile
file by inputtouch .bash_profile
- Open
.bash_profile
file by inputtingopen -e .bash_profile
- In this file, enter
export PATH=${PATH}:/Users/XXX/Library/Android/sdk/platform-tools:/Users/XXX/Library/Android/sdk/tools
- Closing
.bash_profile
file will automatically save it. - Verify whether it's set up successfully by enter
source .bash_profile
- Enter
adb
, if there is no-bash: adb: command not found
, then we are successful.
- close the emulator!
- enter
adb emu kill
to kill one emulator - if you have more than one emulator
- enter
adb devices
to find out the serial numbers of the running emulators adb -s <serial-number> emu kill
to kill specific emulator- for example,
adb -s emulator-5554 emu kill