mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Fix downloading the windows nox artifact
This commit is contained in:
parent
060a192cc7
commit
ad65c6364a
1 changed files with 22 additions and 0 deletions
|
@ -119,6 +119,28 @@ def download_nox_artifact(
|
||||||
assert arch is not None
|
assert arch is not None
|
||||||
assert platform is not None
|
assert platform is not None
|
||||||
|
|
||||||
|
if platform == "windows":
|
||||||
|
if arch in ("x64", "x86_64"):
|
||||||
|
ctx.info(f"Turning passed arch {arch!r} into 'amd64'")
|
||||||
|
arch = "amd64"
|
||||||
|
if arch not in ("amd64", "x86"):
|
||||||
|
ctx.error(
|
||||||
|
"The allowed values for '--arch' on Windows are 'amd64' and 'x86'"
|
||||||
|
)
|
||||||
|
return ExitCode.FAIL
|
||||||
|
else:
|
||||||
|
if arch == "arm64":
|
||||||
|
ctx.info(f"Turning passed arch {arch!r} into 'aarch64'")
|
||||||
|
arch = "aarch64"
|
||||||
|
elif arch == "x64":
|
||||||
|
ctx.info(f"Turning passed arch {arch!r} into 'x86_64'")
|
||||||
|
arch = "x86_64"
|
||||||
|
if arch not in ("x86_64", "aarch64"):
|
||||||
|
ctx.error(
|
||||||
|
f"The allowed values for '--arch' on {platform.title()} are 'x86_64', 'aarch64' or 'arm64'"
|
||||||
|
)
|
||||||
|
return ExitCode.FAIL
|
||||||
|
|
||||||
artifacts_path = tools.utils.REPO_ROOT / ".nox" / nox_env
|
artifacts_path = tools.utils.REPO_ROOT / ".nox" / nox_env
|
||||||
if artifacts_path.exists():
|
if artifacts_path.exists():
|
||||||
ctx.error(
|
ctx.error(
|
||||||
|
|
Loading…
Add table
Reference in a new issue