


Then open you terminal in android studio and run the script file to install the APK.

Save the file in you project directory(although you can keep it any where).also add it to you gitignore if you need. I just copy these commands into a file and save it as run.shĪdb push /home/gautam/sample/app/build/outputs/apk/debug/app-debug.apk /data/local/tmp/Īdb shell pm install -t -r "/data/local/tmp/"Īdb shell am start -n "/.MainActivity" -a -c When you run the app in the android studio the run tab will print out the commands which android studio uses to install the app on the device.
HOW TO INSTALL APK IN ANDROID STUDIO EMULATOR IN MAC WINDOWS
I use this method to install the generated APK to the device using bash script since I'm working on Linux(didn't try this on windows or os x).
