adb shell dumpsys activity top | grep ACTIVITY 栈顶ACTIVITY
adb shell dumpsys activity | grep mCurrentFocus 查看包名
find . -type f -name "ConfirmConnectToWifiNetworkActivity.java" 查找文件所在目录
find . -type f | grep "RotationshowPage" 查找文件名为 的文件
adb shell dumpsys activity com.android.settings 查看当前fragment
adb shell pm path com.android.systemui 查看apk安装路径
adb shell dumpsys package cn.litiaotiao.app 查看apk的信息
adb shell dumpsys activity p com.caf.fmradio 查看服务等
find . -name "Settings.java" 查找文件所在目录
adb shell pm list packages -f |grep com.android.gallery3d 查看安装路径
adb logcat -b all -c 清除所有缓存
adb logcat -b all |grep -i androidzp 过滤关键字
adb logcat -b all > /work/Log/night.txt 打印所有日志,并保存
adb logcat -s androidxx 日志打印 过滤TAG
adb logcat -G 16M 设置logcat⽇志缓存
adb shell dmesg > dmesg.txt kernel日志
adb shell dmesg -C 清空dmesg日志缓存
adb shell dmesg -w 持续抓dmesg日志
adb shell cat /proc/last_kmsg > last_kmsg.txt last_kmsg信息, 基本与dmesg相同
adb shell bugreport > bugreport.txt Android的 bugreport日志
adb shell getprop > props.txt 获取Android属性
adb shell env > env.txt 环境信息
adb shell pm clear <packagename> 清楚应用缓存
adb shell getprop ro.product.cpu.abi 使用adb查看手机是32位还是64位
adb shell pm list packages 查找所有的安装应用
ssh连接 ssh ubuntu@192.168.1.1
拷贝到当前文件下 sudo scp ubuntu@192.168.1.1:/work/modem.zip ./
上传文件到Downloads目录 sudo scp modem.zip ubuntu@192.168.1.1:~/Downloads/