mirror of
https://github.com/opentx/opentx.git
synced 2025-07-23 16:25:16 +03:00
Travis install time reduced (#3493)
This commit is contained in:
parent
7b3dcec30e
commit
f63a9c4cb7
3 changed files with 18 additions and 14 deletions
|
@ -1,4 +1,4 @@
|
|||
#!/usr/bin/env python
|
||||
#!/usr/bin/env python3
|
||||
|
||||
from __future__ import division
|
||||
import sys
|
||||
|
@ -9,12 +9,13 @@ fileout = sys.argv[2]
|
|||
# Read entire file
|
||||
with open(filename, "rb") as fr:
|
||||
sts = fr.read()
|
||||
|
||||
# Parse into chunks of 16 bytes
|
||||
sts = [sts[i:i+16] for i in range(0, len(sts), 16)]
|
||||
|
||||
with open(fileout, "w") as fw:
|
||||
for st in sts:
|
||||
for b in st:
|
||||
fw.write("0x%02x," % ord(b))
|
||||
fw.write("0x%02x," % b)
|
||||
fw.write("\n")
|
||||
fw.write("\n")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue