Merge "Skip non-zip files when refreshing build library" am: 2d4909a1cb
Original change: https://android-review.googlesource.com/c/platform/development/+/1811897 Change-Id: I376dbf4d7cf672a7d64419b6cfae634b5b66c91e
This commit is contained in:
@@ -130,8 +130,9 @@ class TargetLib:
|
||||
if os.path.isdir(path):
|
||||
builds_name = os.listdir(path)
|
||||
for build_name in builds_name:
|
||||
self.new_build(build_name, os.path.join(path, build_name))
|
||||
elif os.path.isfile(path):
|
||||
if build_name.endswith(".zip"):
|
||||
self.new_build(build_name, os.path.join(path, build_name))
|
||||
elif os.path.isfile(path) and path.endswith(".zip"):
|
||||
self.new_build(os.path.split(path)[-1], path)
|
||||
return self.get_builds()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user