There are multiple ways to set the adb server connection information in the
environment. This commit adds support for ADB_SERVER_SOCKET.
Set a valid server socket environment variable:
$ export ADB_SERVER_SOCKET=tcp:localhost:5038
$ adb devices
List of devices attached
* daemon not running; starting now at tcp:localhost:5038
* daemon started successfully
Now dumpapp doesn't fail anymore:
$ scripts/dumpapp
Failure to target device None: no devices/emulators found
It does fail when the socket spec is invalid/unsupported:
$ export ADB_SERVER_SOCKET=nope
$ scripts/dumpapp
...
stetho_open.HumanReadableError: Invalid or unsupported socket spec 'nope' specified in ADB_SERVER_SOCKET.
$ export ADB_SERVER_SOCKET=tcp:localhost:abc
$ scripts/dumpapp
...
stetho_open.HumanReadableError: Invalid integer 'abc' specified in ANDROID_ADB_SERVER_PORT or ADB_SERVER_SOCKET.
There are multiple ways to set the adb server connection information in the environment. This commit adds support for
ADB_SERVER_SOCKET
.Set a valid server socket environment variable:
Now dumpapp doesn't fail anymore:
It does fail when the socket spec is invalid/unsupported: