Skip to content

Commit

Permalink
print progress dots
Browse files Browse the repository at this point in the history
  • Loading branch information
vm03 committed Aug 20, 2019
1 parent f2b247e commit 0f9865c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion payload_dumper.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@ def data_for_op(op,out_file,old_file):
return data

def dump_part(part):
print(part.partition_name)
sys.stdout.write("Processing %s partition" % part.partition_name)
sys.stdout.flush()

out_file = open('%s/%s.img' % (args.out, part.partition_name), 'wb')
h = hashlib.sha256()
Expand All @@ -103,6 +104,10 @@ def dump_part(part):

for op in part.operations:
data = data_for_op(op,out_file,old_file)
sys.stdout.write(".")
sys.stdout.flush()

print("Done")


parser = argparse.ArgumentParser(description='OTA payload dumper')
Expand Down

0 comments on commit 0f9865c

Please sign in to comment.