Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions android_unpinner/vendor/platform_tools/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@

def adb(cmd: str) -> subprocess.CompletedProcess[str]:
"""Helper function to call adb and capture stdout."""
cmd = f"{adb_binary} {cmd}"
if device:
cmd += f" -s {device}"
cmd = f"{adb_binary} -s {device} {cmd}"
logging.debug(f"Using device: {device}")
else:
cmd = f"{adb_binary} -s {device} {cmd}"

try:
proc = subprocess.run(
cmd, shell=True, check=True, capture_output=True, text=True
Expand Down