ADB命令

1.启动app

adb shell am start -n [包名]/[类名]

例:adb shell am start -n com.joe.test/.MainActivity

2.连接了多个设备时,进入指定设备

先输入adb devices 查看设备list

然后输入 adb -s [序列号] shell

3.查看service列表:

adb shell service list

4.检查有没有该service:

adb shell service check [服务名] (这个没有成功啊。搞不懂)

5.查看系统进程并正则匹配:

adb shell ps | grep [匹配字符串]

例:adb shell ps | grep dpl

6.获取apk安装路径:

adb shell pm path +apk包名

例:adb shell pm path com.android.smart.terminal.dplatform

7.查看IP地址:

adb shell netcfg

8.重启adb:

adb shell start adbd

 

posted @ 2019-07-05 10:05  jdhdevelop  阅读(313)  评论(0编辑  收藏  举报