Home

Awesome

ADB Enhanced Downloads PyPI version

Logo

ADB-Enhanced is a Swiss army knife for Android testing and development.

A command-line interface to trigger various scenarios like screen rotation, battery saver mode, data saver mode, doze mode, and permission grant/revocation. It's a wrapper around adb and not a replacement.

Lint Python Lint Markdown Lint YAML

InstallAdbeTest

AdbeInstallTests AdbeUnitTests

Install adb-enhanced via pip Install adb-enhanced via homebrew

AdbeUnitTests-Api16 AdbeUnitTests-Api21 AdbeUnitTests-Api22 AdbeUnitTests-Api23 AdbeUnitTests-Api24 AdbeUnitTests-Api25 AdbeUnitTests-Api26 AdbeUnitTests-Api27 AdbeUnitTests-Api28 AdbeUnitTests-Api29 AdbeUnitTests-Api31 AdbeUnitTests-Api30 AdbeUnitTests-Api31 AdbeUnitTests-Api32 AdbeUnitTests-Api33 AdbeUnitTests-Api34

asciicast

Release announcement

See Release announcement

Installation

Recommended

sudo pip3 install adb-enhanced

Alternative on Mac OS via Homebrew Homebrew package

brew install adb-enhanced

Note

  1. sudo pip install adb-enhanced works only for Python 3. Python 2 is no longer supported.
  2. If you don't have sudo access or you are installing without sudo then adbe might not be configured correctly in the path.
  3. To set up bash/z-sh auto-completion, execute sudo pip3 install infi.docopt-completion && docopt-completion $(which adbe) after installing adb-enhanced.

Examples

Device configuration

Permissions

Interacting with app

Device info

App info

Usage

adbe [options] airplane (on | off)
adbe [options] alarm (all | top | pending | history)
adbe [options] animations (on | off)
adbe [options] app backup <app_name> [<backup_tar_file_path>]
adbe [options] app info <app_name>
adbe [options] app path <app_name>
adbe [options] app signature <app_name>
adbe [options] apps list (all | system | third-party | debug | backup-enabled)
adbe [options] battery level <percentage>
adbe [options] battery reset
adbe [options] battery saver (on | off)
adbe [options] cat <file_path>
adbe [options] clear-data <app_name>
adbe [options] dark mode (on | off)
adbe [options] devices
adbe [options] (enable | disable) wireless debugging
adbe [options] dont-keep-activities (on | off)
adbe [options] doze (on | off)
adbe [options] dump-ui <xml_file>
adbe [options] force-stop <app_name>
adbe [options] gfx (on | off | lines)
adbe [options] input-text <text>
adbe [options] install <file_path>
adbe [options] jank <app_name>
adbe [options] layout (on | off)
adbe [options] location (on | off)
adbe [options] ls [-a] [-l] [-R|-r] <file_path>
adbe [options] mobile-data (on | off)
adbe [options] mobile-data saver (on | off)
adbe [options] mv [-f] <src_path> <dest_path>
adbe [options] notifications list
adbe [options] open-url <url>
adbe [options] overdraw (on | off | deut)
adbe [options] permission-groups list all
adbe [options] permissions (grant | revoke) <app_name> (calendar | camera | contacts | location | microphone | notifications | phone | sensors | sms | storage)
adbe [options] permissions list (all | dangerous)
adbe [options] press back
adbe [options] pull [-a] <file_path_on_android>
adbe [options] pull [-a] <file_path_on_android> <file_path_on_machine>
adbe [options] push <file_path_on_machine> <file_path_on_android>
adbe [options] restart <app_name>
adbe [options] restrict-background (true | false) <app_name>
adbe [options] rm [-f] [-R|-r] <file_path>
adbe [options] rotate (landscape | portrait | left | right)
adbe [options] rtl (on | off)
adbe [options] screen (on | off | toggle)
adbe [options] screenrecord <filename.mp4>
adbe [options] screenshot <filename.png>
adbe [options] show-taps (on | off)
adbe [options] standby-bucket get <app_name>
adbe [options] standby-bucket set <app_name> (active | working_set | frequent | rare)
adbe [options] start <app_name>
adbe [options] stay-awake-while-charging (on | off)
adbe [options] stop <app_name>
adbe [options] top-activity
adbe [options] uninstall [--first-user] <app_name>
adbe [options] wifi (on | off)

Options

-e, --emulator          directs the command to the only running emulator
-d, --device            directs the command to the only connected "USB" device
-s, --serial SERIAL     directs the command to the device or emulator with the given serial number or qualifier.
                        Overrides ANDROID_SERIAL environment variable.
-l                      For long list format, only valid for "ls" command
-R                      For recursive directory listing, only valid for "ls" and "rm" command
-r                      For delete file, only valid for "ls" and "rm" command
-f                      For forced deletion of a file, only valid for "rm" command
-v, --verbose           Verbose mode

Python3 migration timeline

Testing

make lint
make test

Release a new build

A new build can be released using release/release.py script. Build a test release via make release_debug. Build a production release via make release_production

Updating docs for ReadTheDocs

make documentation

Note that this happens automatically during make release_production.

You will have to do brew install pandoc if you are missing pandoc.

Note: The inspiration for this project came from android-scripts.

Packaging status

Contributors

GitHub contributors