LinuxCommandLibrary

adb-shell-pm

Android package manager shell interface

TLDR

List all installed packages

$ adb shell pm list packages
copy
List only system packages
$ adb shell pm list packages -s
copy
List only third-party packages
$ adb shell pm list packages -3
copy
Uninstall a package
$ adb shell pm uninstall [com.example.app]
copy
Clear app data and cache
$ adb shell pm clear [com.example.app]
copy
Get path to APK
$ adb shell pm path [com.example.app]
copy

SYNOPSIS

adb shell pm command [options]

DESCRIPTION

pm (Package Manager) is an Android shell command for managing installed applications. It provides functionality for listing, installing, uninstalling, and querying information about packages on the device.
This tool is more powerful than the standard adb install/uninstall commands, offering options to manage permissions, disable packages, and query detailed package information.

PARAMETERS

list packages [-f] [-d] [-e] [-s] [-3] [-i] [-u] [filter]

List packages (-f: with APK path, -d: disabled, -e: enabled, -s: system, -3: third-party, -i: with installer, -u: include uninstalled)
path package
Print path to the APK
install [-r] [-t] [-d] path
Install package from device path
uninstall [-k] package
Remove package (-k: keep data)
clear package
Delete all data associated with package
enable package
Enable a disabled package
disable package
Disable a package
grant package permission
Grant a permission to a package
revoke package permission
Revoke a permission from a package
dump package
Print package information

CAVEATS

Some operations require system or root privileges. Disabling system packages may cause instability. Package names are case-sensitive. Uninstalling system apps may require root.

HISTORY

The package manager command has been part of Android since its initial release in 2008, providing command-line access to the PackageManager system service.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Bmax Mini PC B2 Power Intel 5205U 8GB DDR4 256GB M.2 NVMe SSD ,HDMI 1.4&DP 1.2, USB3.2,4K Dual Display 2.4G/5G WiFi & BT5.0 Mini Desktop Computers /Office/Design

Bmax Mini PC B2 Power Intel 5205U 8GB DDR4 256GB M.2 NVMe SSD ,HDMI 1.4&DP 1.2, USB3.2,4K Dual Display 2.4G/5G WiFi & BT5.0 Mini Desktop Computers /Office/Design

$169.99
New Raspberry Pi 3 Model B+ Board Raspberry PI 3B+

New Raspberry Pi 3 Model B+ Board Raspberry PI 3B+

$54.00
nuphy Air75 V2 Portable 75% Mechanical Keyboard,Wireless Keyboard

nuphy Air75 V2 Portable 75% Mechanical Keyboard,Wireless Keyboard

$129.95
Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community

nuphy Air75 V2 Portable 75% Mechanical Keyboard,Wireless Keyboard

nuphy Air75 V2 Portable 75% Mechanical Keyboard,Wireless Keyboard

$129.95
KIWITATA 2X Classic SNES USB Controller for PC Gamings, Retro SNES Wired USB Game Emulator Controller for Windows XP 7 8 11 Mac Raspberry Pi

KIWITATA 2X Classic SNES USB Controller for PC Gamings, Retro SNES Wired USB Game Emulator Controller for Windows XP 7 8 11 Mac Raspberry Pi

$16.99
BOSGAME Mini PC N95, Intel 12th Mini Computers| 16GB DDR4 RAM| 512GB M.2 2280 SSD| 4K 60HZ Triple Displays by Dual HDMI+Type-C, 6W TDP Quiet Mini PC, WIFI5, BT 5.0 Office

BOSGAME Mini PC N95, Intel 12th Mini Computers| 16GB DDR4 RAM| 512GB M.2 2280 SSD| 4K 60HZ Triple Displays by Dual HDMI+Type-C, 6W TDP Quiet Mini PC, WIFI5, BT 5.0 Office

$239.99