23 stable releases

Uses new Rust 2024

new 2.1.11 Apr 13, 2025
2.1.10 Mar 12, 2025
2.1.8 Feb 27, 2025
2.1.0 Dec 18, 2024
1.0.7 Sep 28, 2024

#224 in Hardware support

Download history 129/week @ 2024-12-15 5/week @ 2024-12-22 3/week @ 2025-01-05 2/week @ 2025-01-12 504/week @ 2025-01-19 132/week @ 2025-01-26 52/week @ 2025-02-02 210/week @ 2025-02-09 26/week @ 2025-02-16 149/week @ 2025-02-23 73/week @ 2025-03-02 245/week @ 2025-03-09 28/week @ 2025-03-16 4/week @ 2025-03-23 3/week @ 2025-03-30

280 downloads per month

MIT license

205KB
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

~24–52MB
~1M SLoC