aapt

查看安装包信息aapt list apk路径
* aapt list xxx/app-debug.apk 查看apk文件信息并保存到本地(> 重定向符) * aapt list xx/app-debug.apk > /Users/user/Desktop/apk.txt
查看apk权限aapt dump (code) apk路径
* aapt dump permissions /Users/jalon/Downloads/huai/app/build/outputs/apk/debug/app-debug.apk
code说明:
*      strings          Print the contents of the resource table string pool in the APK.
badging Print the label and icon for the app declared in APK.
permissions Print the permissions from the APK.
resources Print the resource table from the APK.
configurations Print the configurations in the APK.
xmltree Print the compiled xmls in the given assets.
xmlstrings Print the strings of the given compiled xml assets.

adb

 安装apk包到手机 adb install -r apk路径
* adb install -r xxx/app-debug.apk

 安装包复制到手机 adb push apk路径 手机路径
* adb push xxx/debug/app-debug.apk  /sdcard
 保存到本地 (adb pull 手机文件 pc路径)
* adb pull sdcard/screenshot.png /Users/user/Desktop/file
 删除文件
  1. adb remount
  2. adb shell
  3. cd sdcard
  4. remove *.apk(remove 文件名)
 查看系统盘符
* adb shell df
 打印Log( | grep + 筛选条件)
* adb shell
* logcat | grep "custominfo"
 在终端中只打印TAG = xyz的日志
* adb logcat -s xyz
 日志保存到手机
* adb logcat -f sdcard/log.txt
 查看已安装的应用
* adb shell pm list package -f | grep "qq"
截屏
* adb shell screencap -p /sdcard/screenshot.png

模拟按键输入(3:home)

* adb shell input keyevent 3
模拟滑动输入(x1 y1 x2 y2)
* adb shell input touchscreen swipe 18 999 18 666

												

aapt&adb笔记的更多相关文章

  1. 【已解决】mac上appium报错:“Could not find aapt Please set the ANDROID_HOME environment variable with the Android SDK root directory path”

    按照网上教程配置完appium环境后,真机跑自动化过程,遇到如下报错: appium报错如下: [ADB] Checking whether aapt is present [ADB] The AND ...

  2. Android学习笔记1 android adb启动失败问题 adb server is out of date. killing...

    下面是Android的学习笔记,原文地址. 我是使用adb devices出现如下红字错误, 使用第一种方法方法,结果关掉豌豆荚就可以了. android adb启动失败问题 adb server i ...

  3. adb相关指令 笔记

      adb相关指令 笔记 1.adb devices 查看物理测试设备或模拟器的相关信息,有三个状态: (1)device 设备已连接到adb服务器上,但该状态并不代表设备已启动完毕可以进行操作: ( ...

  4. 【自动化测试:笔记一】adb命令

    1.查看当前连接的设备数 adb devices 2.连接设备 adb connect <设备名> 3.安装卸载app adb install packagesname adb unins ...

  5. Android学习笔记_60_Android常用ADB命令

    第一部分: 1. ubuntu下配置环境anroid变量: 在终端执行 sudo gedit /etc/profile 打开文本编辑器,在最后追加#set android environment 2. ...

  6. 【转】 Pro Android学习笔记(五五):调试和分析(3):adb命令、模拟器控制台和StrictMode

    目录(?)[-] adb命令 模拟器Console StrictMode adb命令 我们在学习SQLite的使用,介绍过部分adb命令的使用,见Pro Android学习笔记(五):了解Conten ...

  7. 【学习笔记】adb命令

    1.adb connect 连接设备 如:adb connect 127.0.0.1:62001 连接夜神模拟器\adb connect 127.0.0.1:21503 链接逍遥模拟器 adb con ...

  8. 请介绍下 adb、ddms、aapt 的作用

    adb 是 Android Debug Bridge ,Android 调试桥的意思 ddms 是 Dalvik Debug Monitor Service,dalvik 调试监视服务. aapt 即 ...

  9. adb,aapt等命令使用

    adb         install/uninstall:安装/卸载手机中的应用.         devices:查看当前连接到电脑中的设备. adb shell         首先运行adb ...

随机推荐

  1. layui的layer.open()方法查看缩略图 原图缩放

    写在前面 需求是页面上的图片缩略图, 鼠标悬浮时显示原图片, 并按比例缩放. 操作步骤 官方文档 点击跳转 关键属性 1. type: 设置type=1, 以页面的形式展示图片 2.  content ...

  2. win7下查看进程端口

    一. 查看所有进程占用的端口 在开始-运行-cmd,输入:netstat –ano 可以查看所有进程 二.查看占用指定端口的程序 当你在用tomcat发布程序时,经常会遇到端口被占用的情况,我们想知道 ...

  3. MSYS2 更新源

    博客转载自:https://blog.csdn.net/puputaoexin/article/details/81780492 在使用msys2下载文件的时候回出现下载速度奇慢,且经常因为各种原因报 ...

  4. Redis 密码设置 及 带密码访问

    转: Redis 密码设置 如果不加密码,默认只能本机访问,加密码也是为了安全考虑 1.进入Redis 的安装目录,找到redis.conf文件.用vi命令打开文件 输入  / requirepass ...

  5. python中的捕获异常、异常跟踪

    # 捕获异常,打印异常信息 try: 1/0 except Exception as e: print(e) 输出结果是integer division or modulo by zero,只知道是报 ...

  6. Pytorch 类别平衡化处理

    采用  WeightedRandomSampler: def make_weights_for_balanced_classes(images, nclasses): count = [0] * nc ...

  7. PS弧形边缘的去黑色背景色

    按照理论来说,纯色的字体加上纯色的背景,然后保存成png文件,然后用色彩范围选择纯色的背景,去掉背景,这样应该能得到原来设置的纯色的字体,但实际测试后不是这样的.如果是矩形等,是纯色,但是Photos ...

  8. [LeetCode] 236. Lowest Common Ancestor of a Binary Tree 二叉树的最近公共祖先

    Given a binary tree, find the lowest common ancestor (LCA) of two given nodes in the tree. According ...

  9. UE4 window打包ios备忘

    1.生成SHH key 2.安装证书 *.cer,*.p12 以下转自:http://wangjie.rocks/2017/11/30/ue4-ios-build-on-windows/ 问题一 12 ...

  10. 【Tools】Myeclise-2018.12.0 最新破解文件

    Myeclise-2018.12.0 最新破解文件. 最近在写android app登录块,需要用到这个工具,顺手就拿到了,发现资源太少.这里分享给大家. 有币高富帅打赏下载地址: https://d ...