From 122835a32d8656014648823a9178544dbccc7d8b Mon Sep 17 00:00:00 2001 From: Henry Schreiner Date: Thu, 31 Oct 2024 12:17:09 -0400 Subject: [PATCH] fix: windows Signed-off-by: Henry Schreiner --- nox/__main__.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/nox/__main__.py b/nox/__main__.py index e8283412..a1ba7991 100644 --- a/nox/__main__.py +++ b/nox/__main__.py @@ -115,11 +115,12 @@ def run_script_mode(envdir: Path, reuse: bool, dependencies: list[str]) -> NoRet ) venv.create() venv.env["NOX_SCRIPT_MODE"] = "none" - subprocess.run(["uv", "pip", "install", *dependencies], env=venv.env, check=True) + cmd = ["uv", "pip", "install"] if venv.venv_backend == "uv" else ["pip", "install"] + subprocess.run([*cmd, *dependencies], env=venv.env, check=True) if sys.platform.startswith("win"): raise SystemExit( subprocess.run( - sys.argv, + ["nox", sys.argv[1:]], env=venv.env, stdout=None, stderr=None,