adb命令之pm
常用的用法:
查看已经安装的包
pm list packages
查看已经安装的包以及apk路径(-3:只看第三方应用; -s:只看系统应用)
-f: see their associated file.
-d: filter to only show disbled packages.
-e: filter to only show enabled packages.
-s: filter to only show system packages.
-3: filter to only show third party packages.
pm list packages -f -
列出指定包名的APK位置
pm path com.kp.poi
删除某个应用的所有数据(相当于全新安装)
pm clear com.UCMobile
禁用/启用某个应用(disable/enable)
pm disable com.android.systemui
列出硬件信息
pm list features
完整的用法:
usage: pm list packages [-f] [-d] [-e] [-s] [-] [-i] [-u] [--user USER_ID] [FIL
TER]
pm list permission-groups
pm list permissions [-g] [-f] [-d] [-u] [GROUP]
pm list instrumentation [-f] [TARGET-PACKAGE]
pm list features
pm list libraries
pm list users
pm path PACKAGE
pm dump PACKAGE
pm install [-l] [-r] [-t] [-i INSTALLER_PACKAGE_NAME] [-s] [-f]
[--algo <algorithm name> --key <key-in-hex> --iv <IV-in-hex>]
[--originating-uri <URI>] [--referrer <URI>] PATH
pm uninstall [-k] PACKAGE
pm clear [--user USER_ID] PACKAGE
pm enable [--user USER_ID] PACKAGE_OR_COMPONENT
pm disable [--user USER_ID] PACKAGE_OR_COMPONENT
pm disable-user [--user USER_ID] PACKAGE_OR_COMPONENT
pm disable-until-used [--user USER_ID] PACKAGE_OR_COMPONENT
pm block [--user USER_ID] PACKAGE_OR_COMPONENT
pm unblock [--user USER_ID] PACKAGE_OR_COMPONENT
pm grant PACKAGE PERMISSION
pm revoke PACKAGE PERMISSION
pm set-install-location [/auto] [/internal] [/external]
pm get-install-location
pm set-permission-enforced PERMISSION [true|false]
pm trim-caches DESIRED_FREE_SPACE
pm create-user USER_NAME
pm remove-user USER_ID
pm get-max-users pm list packages: prints all packages, optionally only
those whose package name contains the text in FILTER. Options:
-f: see their associated file.
-d: filter to only show disbled packages.
-e: filter to only show enabled packages.
-s: filter to only show system packages.
-: filter to only show third party packages.
-i: see the installer for the packages.
-u: also include uninstalled packages. pm list permission-groups: prints all known permission groups. pm list permissions: prints all known permissions, optionally only
those in GROUP. Options:
-g: organize by group.
-f: print all information.
-s: short summary.
-d: only list dangerous permissions.
-u: list only the permissions users will see. pm list instrumentation: use to list all test packages; optionally
supply <TARGET-PACKAGE> to list the test packages for a particular
application. Options:
-f: list the .apk file for the test package. pm list features: prints all features of the system. pm list users: prints all users on the system. pm path: print the path to the .apk of the given PACKAGE. pm dump: print system state associated w ith the given PACKAGE. pm install: installs a package to the system. Options:
-l: install the package with FORWARD_LOCK.
-r: reinstall an exisiting app, keeping its data.
-t: allow test .apks to be installed.
-i: specify the installer package name.
-s: install package on sdcard.
-f: install package on internal flash.
-d: allow version code downgrade. pm uninstall: removes a package from the system. Options:
-k: keep the data and cache directories around after package removal. pm clear: deletes all data associated with a package. pm enable, disable, disable-user, disable-until-used: these commands
change the enabled state of a given package or component (written
as "package/class"). pm grant, revoke: these commands either grant or revoke permissions
to applications. Only optional permissions the application has
declared can be granted or revoked. pm get-install-location: returns the current install location.
[auto]: Let system decide the best location
[internal]: Install on internal device storage
[external]: Install on external media pm set-install-location: changes the default install location.
NOTE: this is only intended for debugging; using this can cause
applications to break and other undersireable behavior.
[auto]: Let system decide the best location
[internal]: Install on internal device storage
[external]: Install on external media pm trim-caches: trim cache files to reach the given free space. pm create-user: create a new user with the given USER_NAME,
printing the new user identifier of the user. pm remove-user: remove the user with the given USER_IDENTIFIER,
deleting all data associated with that user
adb命令之pm的更多相关文章
- adb shell am broadcast 手动发送广播及adb shell am/pm其他命令
版权声明:本文为博主原创文章,未经博主允许不得转载. https://blog.csdn.net/zi_zhe/article/details/72229201 在命令行可用adb shell am ...
- 分享一个常用Adb命令
分享一个常用Adb命令 首先 首先感谢@xuxu的常用adb命令,收益良多,但是已经不能满足于我,所以补充了下. 再者 好久没发帖了,最近论坛老司机们都在讨论/总结,我就用这个干货回报吧. 最后 基于 ...
- adb 命令
adb命令 su 获取权限 ls 显示目录下的文件 cd / 跳转路径 pm 直接执行设备命令 exit 退出 adb devices 查看设备 adb shell 登录设备shell adb 用桥接 ...
- 常用的adb命令
在平时的工作中,会经常用到adb命令,在这里稍微整理了一下. 一.概要 1.什么是adb? adb全称为Android Debug Bridge,就是起到调试桥的作用.顾名思义,adb就是一个debu ...
- Android 常用 adb 命令
查看原文:http://blog.csdn.net/u010818425/article/details/52266593 (一)基础操作 安装app adb install -r xxx.apk / ...
- Android 常用 adb 命令总结
Android 常用 adb 命令总结 针对移动端 Android 的测试, adb 命令是很重要的一个点,必须将常用的 adb 命令熟记于心, 将会为 Android 测试带来很大的方便,其中很多命 ...
- 【转】Android 常用 adb 命令总结
原文地址:http://testerhome.com/topics/2565 针对移动端 Android 的测试, adb 命令是很重要的一个点,必须将常用的 adb 命令熟记于心, 将会为 Andr ...
- Android命令之-------ADB命令大全
1.显示当前运行的全部模拟器: adb devices2.启动ADB adb start-server3.停止ADB adb kill-server4.安装应用程序: adb ...
- APP测试时常用adb命令
ADB全称Android Debug Bridge, 是android sdk里的一个工具, 用这个工具可以直接操作管理android模拟器或者真实的andriod设备(手机),故在其实工作可以给我们 ...
随机推荐
- 基于NodeJS的14款Web框架
摘要: 在几年的时间里,Node.js逐渐发展成一个成熟的开发平台,吸引了许多开发者.有许多大型高流量网站都采用Node.js进行开发,像PayPal, 此外,开发人员还可以使用它来开发一些快速移动W ...
- keepalived和zookeeper对比
https://blog.csdn.net/vtopqx/article/details/79066703keepalived与zookeeper都可以用来实现高可用,高可用一般跟负载均衡会一起考虑, ...
- 蓝桥杯练习系统算法训练习题加答案java版本
附上百度文库的链接:http://wenku.baidu.com/view/afb78d36b42acfc789eb172ded630b1c59ee9bf7
- 从顶端插入,滚动展示(Demo):
新闻滚动,从顶端插入: <!DOCTYPE html> <html> <head> <script src="/jquery/jquery-1.11 ...
- ubuntu配置ftp
0.sudo apt-get install vsftpd 1.vi /etc/vsftpd.conf 将里面的注释打开 2.sudo service vsftpd restart 3.端口号21
- django项目搭建及Session使用
django+session+中间件 一.使用命令行创建django项目 在指定路径下创建django项目 django-admin startproject djangocommon 在项目目录 ...
- [C++] Virtual Destructor(虚析构函数)
Without Virtual Destructor(虚析构函数) class A{ public: ; A() { cout <<"A()..."<< e ...
- [模板]RMQ(冲刺准备中)
洛谷P3865 注意:位运算一定要加括号!因为他的优先级没有加减法高: 注意在预处理的时候判断的是前一个区间是否完整,故 i+(1<<(j-1))-1<=n; 取logn时最好多加一 ...
- xml与java代码相互装换的工具类
这是一个java操作xml文件的工具类,最大的亮点在于能够通过工具类直接生成xml同样层次结构的java代码,也就是说,只要你定义好了xml的模板,就能一键生成java代码.省下了自己再使用工具类写代 ...
- Git & Github使用总结
Linux下git的安装 在终端下输入 git , 看系统有没有安装git. 如果没有安装则会出现以下提醒: The program 'git' is currently not installed. ...