User Tools

Site Tools


android:oneplus:adb

This is an old revision of the document!


ADB Commands

Command InstructionDescription
adb devices [-l]List connected devices (-l for long output)
adb helpShow this help message
adb versionShow version num
adb push [–sync] LOCAL… REMOTECopy local files/directories to device –sync: only push files that are newer on the host than the device
adb pull [-a] REMOTE… LOCALCopy files/dirs from device -a: preserve file timestamp and mode
adb shell [-e ESCAPE] [-n] [-Tt] [-x] [COMMAND…]Run remote shell command (interactive shell if no command given)
-e: choose escape character, or “none”; Default '~'
-n: don't read from stdin
-T: disable pty allocation
-t: allocate a pty if on a tty (-tt: force pty allocation)
-x: disable remote exit codes and stdout/stderr separation
adb install [-lrtsdg] [–instant] PACKAGE
adb install-multiple [-lrtsdpg] [–instant] PACKAGE…
Push one or more packages to the device and install them atomically
-r: replace existing application
-t: allow test packages
-d: allow version code downgrade (debuggable packages only)
-p: partial application install (install-multiple only)
-g: grant all runtime permissions
–abi ABI: override platform's default ABI
–instant: cause the app to be installed as an ephemeral install app
–no-streaming: always push APK to device and invoke Package Manager as separate steps
–streaming: force streaming APK directly into Package Manager
–fastdeploy: use fast deploy
–no-fastdeploy: prevent use of fast deploy
–force-agent: force update of deployment agent when using fast deploy
–date-check-agent: update deployment agent when local version is newer and using fast deploy
–version-check-agent: update deployment agent when local version has different version code and using fast deploy
adb reboot bootloaderReboot the device to bootloader.
adb reboot recoveryReboot to recovery too.
adb reboot sideload Sideload reboots into recovery and automatically starts sideload mode
adb reboot sideload-auto-rebootSame but reboots after sideloading.
adb sideload OTAPACKAGESideload the given full OTA package
adb rootRestart adbd with root permissions
adb unrootRestart adbd without root permissions
adb usbRestart adbd listening on USB
adb start-serverEnsure that there is a server running
adb kill-serverKill the server if it is running
adb reconnectKick connection from host side to force reconnect
adb reconnect deviceKick connection from device side to force reconnect
android/oneplus/adb.1600375040.txt.gz · Last modified: (external edit)