Skip to content
This repository was archived by the owner on Jan 10, 2023. It is now read-only.

Commit e0f25ea

Browse files
committed
Push directories
1 parent 05339fb commit e0f25ea

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

adb/adb_commands.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,11 @@ def Push(self, source_file, device_filename, mtime='0', timeout_ms=None):
151151
mtime: Optional, modification time to set on the file.
152152
timeout_ms: Expected timeout for any part of the push.
153153
"""
154+
155+
if os.path.isdir(source_file):
156+
for dir in os.listdir(source_file):
157+
return self.Push(os.path.join(source_file, dir), device_filename + "/" + dir)
158+
154159
connection = self.protocol_handler.Open(
155160
self.handle, destination='sync:',
156161
timeout_ms=timeout_ms)

0 commit comments

Comments
 (0)