Skip to content

Commit

Permalink
Print a little info
Browse files Browse the repository at this point in the history
  • Loading branch information
Huite committed Dec 17, 2023
1 parent 374045b commit 710c6a6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion .github/workflows/create_archive.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,13 @@
# Use the RUNNER_OS variable on the Github Runner. Use platform system locally.
system = os.environ.get("RUNNER_OS", platform.system())
zippath = shutil.make_archive(f"dist/gistim-{system}", "zip", "dist/gistim")
print(f"Created: {zippath}")

# Create a checksum
with open(zippath, "rb", buffering=0) as f:
sha256_hash = hashlib.file_digest(f, "sha256").hexdigest()

with open(f"dist/sha256-checksum-{system}.txt", "w") as f:
txt_path = f"dist/sha256-checksum-{system}.txt"
print(f"Writing checksum to: {txt_path}")
with open(txt_path, "w") as f:
f.write(sha256_hash)

0 comments on commit 710c6a6

Please sign in to comment.