zoukankan      html  css  js  c++  java
  • android ADB的简单实用实践

    Using activity manager

    // app 分辨率高 测试低分辨率  用来做屏幕适配

    Override emulator/device display density. This command is helpful for testing your app across different screen densities on high-density screen environment using a low density screen, and vice versa.

    1.display-density <dpi>

    eg:

    am display-density 480

     

    Override emulator/device display size. This command is helpful for testing your app across different screen sizes by mimicking a small screen resolution using a device with a large screen, and vice versa.

    2.display-size [reset|<WxH>]  

    eg:

    am display-size 1280x800

    Kill all background processes.

    kill-all

     

    3.adb shell pm uninstall []

    eg:

    adb shell pm install /storage/emulated/0/Download/app-release.apk

    可能出现问题:

    Failure [INSTALL_FAILED_INVALID_URI]

    原因,你手机上存在该项目。所以先卸载后安装。

    adb shell pm uninstall com.lskj.rrhr.shortkeytest 红色部分指的是apk 的package  

    manifest package
    你可能关心怎么将apk 传到手机活着模拟器。
    adb push [apk电脑本地路径] [手机上的目标路径]
    eg:adb push app/app-release.apk /storage/emulated/0/Download

    4.adb shell pm install [手机上apk的路径]

    5.adb push [apk电脑本地路径] [手机上的目标路径]

    6.adb devices 查看当前所有的设备

     7.adb pull <远程路径> <本地路径>

     

     

     

     

     

  • 相关阅读:
    计算机二级Python
    vivado三人表决仿真
    verilog设计加法器
    超前进位加法器
    OO第二单元总结
    OO第一单元总结
    第一次阅读作业
    安卓计算器
    安卓第四周作业
    第十四周作业
  • 原文地址:https://www.cnblogs.com/ClodThunder/p/5925780.html
Copyright © 2011-2022 走看看