Moler provides ADB command support through a small set of purpose-built classes. All ADB commands inherit fromDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/nokia/moler/llms.txt
Use this file to discover all available pages before exploring further.
GenericAdbCommand (moler.cmd.adb.generic_adb_command), which itself extends CommandTextualGeneric.
ADB commands assume the
adb binary is on the system PATH and at least one Android device is connected or authorised via USB/TCP.Command list
| Class | Module | Shell command |
|---|---|---|
AdbShell | moler.cmd.adb.adb_shell | adb shell / adb -s <serial> shell |
GenericAdbCommand | moler.cmd.adb.generic_adb_command | (abstract base) |
Detailed reference
AdbShell — moler.cmd.adb.adb_shell
Opens an interactive adb shell session on the target Android device, changing the active prompt to the device shell prompt. Command failure indicators (command not found, error:, etc.) automatically set a CommandFailure exception.
Moler connection to the host machine running
adb.Device serial number as shown in
adb devices. When provided, the command runs as adb -s <serial_number> shell.Regex for the starting shell prompt (on the host). Defaults to generic detection.
Regex for the device shell prompt. If
prompt_from_serial_number=True this is auto-generated.Shell command sent after connection to set the session timeout.
Shell command sent after connection to customise the prompt (e.g.
export PS1=...).Newline character(s) used on the Android device. Default
"\n".Allow extra newlines after the expected prompt. Default
False.When
producing a unique prompt like
True, auto-generates an expected_prompt and set_prompt from serial_numberproducing a unique prompt like
adb_shell@<serial> $. Default False.AdbShell is a connection-changing command. It does not return a data dict; success means the active connection prompt has changed to the device shell. ret_required is False.