2011-12-22 5 views
4

콘솔에서 에뮬레이터의 apk를 시작하려면 어떻게해야합니까? 정확한 명령을 찾을 수 없었습니다.에뮬레이터의 명령 줄에서 apk를 실행하는 방법

VM에서 우분투가 실행되고 거기 에뮬레이터가 있습니다. 이제 설치 (App.apk -works 설치 adb!)하고 명령 줄에서 실행하십시오.

미리 감사드립니다.

+0

가능한 복제 [어떻게 할 APK 설치 f 안드로이드 에뮬레이터의 ile?] (https://stackoverflow.com/questions/3480201/how-do-you-install-an-ap-file-in-the-android-emulator) –

답변

10

설치 : 이제

adb -e install -r "your-apk-file-complete-path" 

실행 :의

am [start|instrument] 
am start [-a <action>] [-d ] [-t <mime_type>] 
[-c <category> [-c <category>] ...] 
[-e <extra_key> <extra_value> [-e <extra_key> <extra_value> ...] 
[-n <component>] [-D] [<uri>] 
am instrument [-e <arg_name> <arg_value>] [-p <prof_file>] 
[-w] <component> 

샘플 실행 코드

am start -a android.intent.action.MAIN -n 
com.abhi.ui/com.abhi.ui.LaunchIt 
+2

다음과 같이 입력해야합니다 : adb shell am start ... (on v1.0.29) – Nobu

관련 문제