[Cryptech-Commits] [releng/alpha] branch python3 updated: More fun with str and bytes
git at cryptech.is
git at cryptech.is
Mon Jul 13 03:15:02 UTC 2020
This is an automated email from the git hooks/post-receive script.
sra at hactrn.net pushed a commit to branch python3
in repository releng/alpha.
The following commit(s) were added to refs/heads/python3 by this push:
new 68f48b7 More fun with str and bytes
68f48b7 is described below
commit 68f48b7e850de48063d95645c3d76e0a2be5c079
Author: Rob Austein <sra at hactrn.net>
AuthorDate: Sun Jul 12 23:14:47 2020 -0400
More fun with str and bytes
---
scripts/build-firmware-package.py | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/scripts/build-firmware-package.py b/scripts/build-firmware-package.py
index 1a96fc7..4f078f4 100755
--- a/scripts/build-firmware-package.py
+++ b/scripts/build-firmware-package.py
@@ -14,10 +14,10 @@ parser.add_argument("firmware", nargs = "+", help = "firmware
args = parser.parse_args()
tar = tarfile.TarFile.open(fileobj = args.tarfile, mode = "w|gz")
-head = subprocess.check_output(("git", "rev-parse", "HEAD")).strip()
-time = subprocess.check_output(("git", "show", "-s", "--format=%ct", "HEAD")).strip()
+head = subprocess.check_output(("git", "rev-parse", "HEAD")).strip().decode()
+time = subprocess.check_output(("git", "show", "-s", "--format=%ct", "HEAD")).strip().decode()
commits = dict((path, hash) for hash, path, branch in
- (line.split() for line in subprocess.check_output(("git", "submodule", "status")).splitlines()))
+ (line.decode().split() for line in subprocess.check_output(("git", "submodule", "status")).splitlines()))
sha256 = {}
for fn in args.firmware:
@@ -34,7 +34,7 @@ with tempfile.NamedTemporaryFile() as f:
jf = gpg.stdin
else:
jf = f
- json.dump(dict(head = head, time = time, commits = commits, sha256 = sha256), jf, indent = 2)
+ jf.write(json.dumps(dict(head = head, time = time, commits = commits, sha256 = sha256), indent = 2).encode())
if use_gpg:
gpg.stdin.close()
if gpg.wait():
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Commits
mailing list