From d490a400d6b820b30c10918785c39a902175391a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Brunner?= Date: Mon, 9 May 2022 13:34:15 +0200 Subject: [PATCH] Fix publish --- c2cciutils/publish.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/c2cciutils/publish.py b/c2cciutils/publish.py index ae9b08bac..2a3a38f87 100644 --- a/c2cciutils/publish.py +++ b/c2cciutils/publish.py @@ -269,7 +269,7 @@ def pip( dist = os.path.join(cwd, 'dist') if not os.path.exists(dist): os.mkdir(dist) - if os.path.exists("setup.py"): + if os.path.exists(os.path.join(cwd, "setup.py")): cmd = ["python3", "./setup.py", "egg_info", "--no-date"] cmd += ( ["--tag-build=dev" + datetime.datetime.now().strftime("%Y%m%d%H%M%S")] @@ -278,8 +278,7 @@ def pip( ) cmd.append("bdist_wheel") else: - cwd = os.path.join(cwd, 'dist') - os.mkdir(cwd) + os.mkdir(dist) cmd = ["pip", "wheel", "--no-deps", "--wheel-dir=dist", '.'] cmd = package.get("build_command", cmd) subprocess.check_call(cmd, cwd=cwd, env=env)