android adb 命令

来源:互联网 发布:淘宝免费加盟网店 编辑:程序博客网 时间:2024/06/10 14:57
1.adb push
adb push <local> <remote>  //copy 文件到android设备
2.adb pull
adb pull <remote> [<local>] //从android设备copy 文件
3.adb shell  //进入设备的终端
4.adb install 安装apk
5.adb root
restarts the adbd daemon with root permissions
6.adb remount
remounts the /system partition on the device read-write
# adb remount
remount succeeded
之后就可以向系统的/system 目录pull/push
7. adb reboot [bootloader|recovery]
进入bootloader recovery模式
8.adb kill-server 结束adbd服务
9.adb start-server 启动adbd 服务
10.adb bugreport
返回dumpsys、dumpstate、logcat的输出用于分析错误
adb bugreport > bugreport.log
11.adb get-serialno
获取设备的序列号
12.获取屏的参数
# adb shell wm size  查看屏幕分辨率
Physical size: 1440x2560

#adb shell wm size 640x480 设置并生效
# adb shell wm size reset 复位

# adb shell wm density 查看屏幕密度
Physical density: 560

13.列出设备所用app的包名
# adb shell pm list packages
14.查看设备型号
# adb shell getprop ro.product.mode