From 6ff7d0a7966b7ec2af1d2ea7b2fcbed98848c9a8 Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Mon, 3 Jul 2023 16:59:23 +0200 Subject: [PATCH] Fix mistake in PyPI release instructions, improve console output --- release/pypi/README.md | 6 +++--- release/pypi/upload-release.py | 8 +++++--- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/release/pypi/README.md b/release/pypi/README.md index dba3ea11253..560fbda01d7 100644 --- a/release/pypi/README.md +++ b/release/pypi/README.md @@ -1,4 +1,4 @@ -# PyPi Release Publishing +# PyPI Release Publishing ### Setup @@ -28,8 +28,8 @@ Check download page for Git hash. Run checks: - ./upload-release.py --version X.X.X --hash abcd1234 --check + ./upload-release.py --version X.X.X --git-hash abcd1234 --check Upload: - ./upload-release.py --version X.X.X --hash abcd1234 + ./upload-release.py --version X.X.X --git-hash abcd1234 diff --git a/release/pypi/upload-release.py b/release/pypi/upload-release.py index 87bb4c31174..d3bb1993493 100755 --- a/release/pypi/upload-release.py +++ b/release/pypi/upload-release.py @@ -51,17 +51,19 @@ with tempfile.TemporaryDirectory() as tmp_dir: # Unzip. with zipfile.ZipFile(filepath, "r") as zipf: zipf.extractall(path=tmp_dir) + print("") - wheels = glob.glob(tmp_dir / "*.whl") + wheels = glob.glob(str(tmp_dir / "*.whl")) print("Wheels:") print("\n".join(wheels)) if len(platforms) != len(wheels): sys.stderr.write("Unexpected number of whl files.") sys.exit(1) + print("") # Check and upload. print("Twine:") - subprocess.run(["twine", "check", " ".join(wheels)], check=True) + subprocess.run(["twine", "check"] + wheels, check=True) if not args.check: - subprocess.run(["twine", "upload", "--repository", "bpy", "--verbose", " ".join(wheels)], check=True) + subprocess.run(["twine", "upload", "--repository", "bpy", "--verbose"] + wheels, check=True)