#android #adb #usb #tcp #debugging

app adb_cli

Rust ADB (Android Debug Bridge) CLI

22 stable releases

new 2.1.10 Mar 12, 2025
2.1.8 Feb 27, 2025
2.1.0 Dec 18, 2024
2.0.5 Nov 18, 2024
1.0.7 Sep 28, 2024

#200 in Hardware support

Download history 147/week @ 2024-11-19 110/week @ 2024-11-26 37/week @ 2024-12-03 5/week @ 2024-12-10 132/week @ 2024-12-17 4/week @ 2025-01-07 1/week @ 2025-01-14 587/week @ 2025-01-21 58/week @ 2025-01-28 45/week @ 2025-02-04 222/week @ 2025-02-11 13/week @ 2025-02-18 196/week @ 2025-02-25 115/week @ 2025-03-04

547 downloads per month

MIT license

200KB
4.5K SLoC

adb_cli

MIT licensed Crates.io Total Downloads

Rust binary providing an improved version of adb CLI.

Rust binary

This crate provides a lightweight binary based on the adb_client crate. You can install it by running the following command :

cargo install adb_cli 

Usage is quite simple, and tends to look like adb:

  • To use ADB server as a proxy:
user@laptop ~/adb_client (main)> adb_cli local --help
Device related commands using server

Usage: adb_cli local [OPTIONS] <COMMAND>

Commands:
  shell          Spawn an interactive shell or run a list of commands on the device
  pull           Pull a file from device
  push           Push a file on device
  stat           Stat a file on device
  run            Run an activity on device specified by the intent
  reboot         Reboot the device
  install        Install an APK on device
  framebuffer    Dump framebuffer of device
  host-features  List available server features
  list           List a directory on device
  logcat         Get logs of device
  help           Print this message or the help of the given subcommand(s)

Options:
  -a, --address <ADDRESS>  [default: 127.0.0.1:5037]
  -s, --serial <SERIAL>    Serial id of a specific device. Every request will be sent to this device
  -h, --help               Print help
  • To interact directly with end devices
user@laptop ~/adb_client (main)> adb_cli usb --help
Device commands via USB, no server needed

Usage: adb_cli usb [OPTIONS] --vendor-id <VID> --product-id <PID> <COMMAND>

Commands:
  shell   Spawn an interactive shell or run a list of commands on the device
  pull    Pull a file from device
  push    Push a file on device
  stat    Stat a file on device
  reboot  Reboot the device
  help    Print this message or the help of the given subcommand(s)

Options:
  -v, --vendor-id <VID>                    Hexadecimal vendor id of this USB device
  -p, --product-id <PID>                   Hexadecimal product id of this USB device
  -k, --private-key <PATH_TO_PRIVATE_KEY>  Path to a custom private key to use for authentication
  -h, --help                               Print help

Dependencies

~23–51MB
~1M SLoC