android_system_core/adb
Scott Anderson 2ca3e6b35f adb: Generalizing -s to take qualifiers.
Prior to this change, -s could take either a serial number or a
device path (e.g. "-s 01498B1F02015015" or "-s usb:1-4.2").  This
change extends -s to also allow product, model or device names
(e.g. "-s product:mysid").  These new qualifiers will only be
available on devices that are running an adb daemon that provides
properties in the connect message per Change-Id:
    I09200decde4facb8fc9b4056fdae910155f2bcb9

The product, model and device are derived from the
ro.product.name, ro.product.model and ro.product.device
properties respectively.  They are prefixed with "product:",
"model:" or "device:" as appropriate.  In addition, any
non-alphanumerics in the model are changed to underscores.

If the -s parameter matches multiple devices, the result will be
the same as when multiple devices are connected but no -d, -e or
-s option is specified.  In general, this means the user will get
"error: more than one device".  However for get-state,
get-devpath and get-serialno, they will get "unknown".

The format of "devices -l" was changed to list all of the
qualifiers that are available.  The following example output
(with the last digits of the serial numbers replaced with X's) is
with a Galaxy Prime with an older adb daemon and another Galaxy
Prime and Galaxy S both with the enhanced adb daemons:

List of devices attached
016B75D60A0060XX       device usb:2-5 product:mysid model:Galaxy_Nexus device:toro
3731B535FAC200XX       device usb:1-4.2 product:soju model:Nexus_S device:crespo
01498B1F020150XX       device usb:1-4.1

Note that the serial number and state are now column oriented
instead of tab delimited.  After the serial number and state, all
qualifiers are listed with each preceded by a space.  The output
of the original devices command (without -l) is unchanged.

Change-Id: Iceeb2789874effc25a630d514a375d6f1889dc56
Signed-off-by: Scott Anderson <saa@android.com>
2012-06-05 11:13:40 -07:00
..
Android.mk Remove the simulator target from all makefiles. 2011-07-11 22:12:32 -07:00
MODULE_LICENSE_APACHE2
NOTICE
OVERVIEW.TXT
SERVICES.TXT adb: Add ability to specify device path 2012-04-20 11:21:14 -07:00
adb.c adb: Generalizing -s to take qualifiers. 2012-06-05 11:13:40 -07:00
adb.h adb: Generalizing -s to take qualifiers. 2012-06-05 11:13:40 -07:00
adb_client.c adb: fix subprocess exit handling, oom adjust fixes, extra debugging. 2011-03-28 14:12:22 -07:00
adb_client.h
backup_service.c Fix hang after end of backup 2011-06-21 16:05:17 -07:00
commandline.c adb: Generalizing -s to take qualifiers. 2012-06-05 11:13:40 -07:00
console.c
fdevent.c adb: keep mac build happy 2011-03-29 12:36:22 -07:00
fdevent.h adb: fix subprocess exit handling, oom adjust fixes, extra debugging. 2011-03-28 14:12:22 -07:00
file_sync_client.c adb: fix subprocess exit handling, oom adjust fixes, extra debugging. 2011-03-28 14:12:22 -07:00
file_sync_service.c adb: fix subprocess exit handling, oom adjust fixes, extra debugging. 2011-03-28 14:12:22 -07:00
file_sync_service.h adb: Improved detection of big endian architecture 2010-10-16 14:35:28 +02:00
framebuffer_service.c fix [3374821] Cannot take screenshot of HC preview 2011-02-09 12:56:25 -08:00
get_my_path_darwin.c
get_my_path_freebsd.c
get_my_path_linux.c
get_my_path_windows.c
jdwp_service.c Fix adb leaking file descriptors to forked processes 2011-02-03 15:26:45 -05:00
log_service.c
mutex_list.h adb: fix subprocess exit handling, oom adjust fixes, extra debugging. 2011-03-28 14:12:22 -07:00
protocol.txt adb: Transmit key properties in banner of connect message 2012-06-05 11:04:55 -07:00
remount_service.c
services.c Reimplement the "adb root" command to more closely match its previous behavior 2011-06-22 08:36:53 -04:00
sockets.c adb: Generalizing -s to take qualifiers. 2012-06-05 11:13:40 -07:00
sockets.dia
sysdeps.h adb: fix subprocess exit handling, oom adjust fixes, extra debugging. 2011-03-28 14:12:22 -07:00
sysdeps_win32.c Fixes ADB crash on Windows due to large number of connections. do not merge. 2011-12-05 13:14:23 -08:00
test_track_devices.c
test_track_jdwp.c
transport.c adb: Generalizing -s to take qualifiers. 2012-06-05 11:13:40 -07:00
transport.h adb: fix subprocess exit handling, oom adjust fixes, extra debugging. 2011-03-28 14:12:22 -07:00
transport_local.c Cherry-picked from c4f37eed7 in master. Do not merge. 2012-01-10 16:19:09 -08:00
transport_usb.c adb: Improved detection of big endian architecture 2010-10-16 14:35:28 +02:00
usb_libusb.c adb: Add ability to specify device path 2012-04-20 11:21:14 -07:00
usb_linux.c adb: Add ability to specify device path 2012-04-20 11:21:14 -07:00
usb_linux_client.c adb: Add ability to specify device path 2012-04-20 11:21:14 -07:00
usb_osx.c adb: Add ability to specify device path 2012-04-20 11:21:14 -07:00
usb_vendors.c Add USB vendor IDs for Quanta, INQ and Sony. 2012-01-24 11:18:50 -08:00
usb_vendors.h adb: Add vendor IDs for iRiver, Compal and T & A Mobile Phones 2011-07-11 09:39:39 -04:00
usb_windows.c adb: Add ability to specify device path 2012-04-20 11:21:14 -07:00
utils.c
utils.h