Move assertion that file is present to earlier in function so we fail fast

This commit is contained in:
David Dworken 2023-11-08 18:19:55 -08:00
parent 79a61c1b1d
commit ed6d472409
No known key found for this signature in database

View File

@ -3,6 +3,9 @@ import time
import subprocess import subprocess
def main(): def main():
assertPresentAndNotAscii("hishtory-darwin-arm64")
assertPresentAndNotAscii("hishtory-darwin-amd64")
print("before sha1sum:") print("before sha1sum:")
os.system("sha1sum hishtory-* 2>&1") os.system("sha1sum hishtory-* 2>&1")
print("before sha256sum:") print("before sha256sum:")
@ -11,11 +14,6 @@ def main():
print("file:") print("file:")
os.system("file hishtory-* 2>&1") os.system("file hishtory-* 2>&1")
assertPresentAndNotAscii("hishtory-darwin-arm64")
assertPresentAndNotAscii("hishtory-darwin-amd64")
# TODO: Update this file to fail if the input files don't exist
print("signing...") print("signing...")
os.system(""" os.system("""
set -emo pipefail set -emo pipefail