[Android Tips] 25. ADB Command Note
copy from https://github.com/operando/Android-Command-Note
Android Command Note
Logcat
adb logcat -v time
adb logcat -v time -b main
adb logcat -v time -b system
adb logcat -v time -b events
adb logcat -v time -b radio
adb shell logcat -b all
adb logcat -B
Android 6.0〜
adb shell logcat -v color
Android 7.0〜
adb logcat -e android
adb logcat -m 100
log
adb shell log [message]
adb shell log -t [tag name] [message]
adb shell log -p [log level] [message]
mount
$ adb shell
$ su
# mount -o rw,remount /system
Bugreport
adb bugreport
Application
adb install [Apk File]
adb uninstall [Package Name]
pm - PackageManager
adb shell pm list packages
adb shell pm list packages -e
adb shell pm list packages -d
adb shell pm list packages -s
adb shell pm list packages -3
dumpsys
adb shell dumpsys
adb shell dumpsys [system service]
adb shell dumpsys service [service name]
adb shell dumpsys activity activities
adb shell dumpsys activity top
adb shell dumpsys activity all
adb shell dumpsys activity provider
adb shell dumpsys activity provider all
adb shell dumpsys gfxinfo
adb shell dumpsys jobscheduler
adb shell dumpsys netpolicy
Root
adb root
Key Event
adb shell input keyevent [event key]
adb shell input keyevent KEYCODE_HOME
adb shell input keyevent KEYCODE_BACK
adb shell input keyevent KEYCODE_MENU
Alarm
adb shell dumpsys alarm
System properties
adb shell getprop
adb shell getprop [property name]
adb shell setprop [property name] [property value]
screenrecord
adb shell screenrecord /sdcard/test.mp4
adb shell screenrecord --size 720x1080 /sdcard/test.mp4
adb shell screenrecord --bit-rate 10000000 /sdcard/test.mp4
adb shell screenrecord --time-limit 120 /sdcard/test.mp4
adb shell screenrecord --bugreport /sdcard/test.mp4
"unofficial" options
adb shell screenrecord --rotate /sdcard/test.mp4
adb shell screenrecord --output-format raw-frames /sdcard/test
screenrecordの"unofficial" optionsは夢がいっぱいだった
Date
adb shell date -s YYYYMMDD.hhmmss
YYYYMMDD:年月日 hhmmss:時分秒
要Root
【Android】adb shell date は System User or radio Groupじゃないと反映されない
Windows
adb shell date -s %date:0,4%%date:5,2%%date:8,2%.%time:0,2%%time:3,2%%time:6,2%
Linux or Mac
adb shell date -s $(date +"%Y%m%d.%H%M%S")
Dropbox
adb shell dumpsys dropbox
adb shell dumpsys dropbox --print
adb shell dumpsys dropbox --file
Lint
lint [application directory] --html [file name].html
lint [application directory] --simplehtml [file name].html
Windows
lint [application directory] --fullpath --quiet --html lint_%date:0,4%%date:5,2%%date:8,2%-%time:0,2%%time:3,2%%time:6,2%.html
Linux or Mac
lint [application directory] --fullpath --quiet --html lint_$(date +"%Y%m%d-%H%M%S").html
Kernal
adb shell dmesg
adb shell cat /proc/kmsg
Permission
adb shell pm list permissions -d -g
adb shell pm grant [permission.name] ...
adb shell pm revoke [permission.name] ...
Other
adb shell printenv
adb reboot
adb shell reboot recovery
adb pull [Unit Path] [Local Path]
adb push [File Path] [Unit Path]
adb shell input text [string]
adb jdwp
adb shell am start -a android.settings.WEBVIEW_SETTINGS
[Android Tips] 25. ADB Command Note的更多相关文章
- How to Use Android ADB Command Line Tool
Android Debug Bridge (adb) is a tool that lets you manage the state of an emulator instance or Andro ...
- 【原创】Android开发之ADB及ADB SHELl命令的应用
adb的全称为Android Debug Bridge,就是起到调试桥的作用.通过adb我们可以在Eclipse中方面通过DDMS来调试Android程序,说白了就是debug工具.adb的工作方式比 ...
- Android Tips – 填坑手册
出于: androidChina http://www.androidchina.net/3595.html 学习 Android 至今,大大小小的坑没少踩,庆幸的是,在强大的搜索引擎与无私奉献的 ...
- 【转】Android开发调试工具ADB的使用
原文网址:http://www.cnblogs.com/meil/archive/2012/05/24/2516055.html ADB(Android Debug Bridge)是Android S ...
- 解决adb command not found以及sdk环境配置
解决adb command not found以及sdk环境配置 分类: mark 2013-10-02 09:41 2975人阅读 评论(0) 收藏 举报 原文地址:http://www.cnblo ...
- mac上adb command not found
第一种报错(使用的自带mac命令行) bash: adb: command not found 1.vim ~/.bash_profile ,如果.bash_profile不存在,先touch ~/. ...
- 解决Mac上adb: command not found问题
使用mac进行开发的时候,有时候需要使用adb指令来进行一些操作,但是如果没有配置过Android环境变量,可能会出现adb: command not found的问题,查了一些资料,这里记录一下ma ...
- ionic打包apkFailed to execute shell command "input,keyevent,82"" on device: Error: adb: Command failed with exit code 137
错误代码如下 BUILD SUCCESSFUL in 12s 46 actionable tasks: 1 executed, 45 up-to-date Built the following ap ...
- 转:Android 调试桥(adb)是多种用途的工具
转自:http://my.oschina.net/xuwa/blog/1574 Android 调试桥(adb)是多种用途的工具,该工具可以帮助你你管理设备或模拟器 的状态. 可以通过下列几种方法加入 ...
随机推荐
- 打造自己的php动态连接库文件
http://blog.163.com/weibin_li/blog/static/1901464172012325115517181/
- 创建ACCESS数据库,并且创建表和数据。重点:关闭ACCESS数据库引用
/// <summary> /// 创建ACCESS数据库,并且创建表和数据 /// </summary> /// <param name="dictTable ...
- Codeforces525E Anya and Cubes(双向搜索)
题目 Source http://codeforces.com/contest/525/problem/E Description Anya loves to fold and stick. Toda ...
- 关于action和category的认知区别
在我的了解, action: intent 有一个或多个action,如果过滤规则中能够匹配到其中一个,是可以成功的 category: intent有一个或多个category,过滤规则需要满足对应 ...
- YUM源设置
1挂载光盘 先创建一个文件 /aaa 然后挂载mount /dev/cdrom /aaa 进入 /aaa ls 查看是否挂载OK 2进入yum文件夹.将除Media以外的所有文件名改为XXXXXX ...
- Hibernate学习笔记3
---恢复内容开始--- 一.hibernate如何转化jdbc代码实例[通过hibernate构建jdbc后往数据库传对象] import java.sql.Connection;import ja ...
- HDU1671 字典树
Phone List Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total ...
- PHP连接数据库的方法
mysql可通过两种方式通过PHP和web相连,一种通过php的mysql相关函数,另一种通过php的ODBC相关函数. 相关函数如下: MYSQL函数 mysql_affected_rows: 得到 ...
- PHP 使用 debug_print_backtrace() 或 debug_backtrace() 打印栈轨迹
<?php /* 使用debug_print_backtrace() 或 debug_backtrace() 打印栈轨迹 */ function fun1() { print "Hel ...
- java容器collection的一些简单特点
1.List ArrayList 可随机访问元素,但中间插入和一处元素较慢 LinkedList 在中间进行的插入和删除操作代价较小,随机访问比ArrayList较慢 特性集比ArrayList大 2 ...