2020-06-18 07:06:33 +00:00
|
|
|
diff --git a/pre_commit/languages/node.py b/pre_commit/languages/node.py
|
2023-03-15 16:39:30 +00:00
|
|
|
index 66d6136..e3f1bac 100644
|
2020-06-18 07:06:33 +00:00
|
|
|
--- a/pre_commit/languages/node.py
|
|
|
|
+++ b/pre_commit/languages/node.py
|
2023-03-15 16:39:30 +00:00
|
|
|
@@ -83,7 +83,7 @@ def install_environment(
|
|
|
|
# https://msdn.microsoft.com/en-us/library/windows/desktop/aa365247(v=vs.85).aspx?f=255&MSPPError=-2147217396#maxpath
|
|
|
|
if sys.platform == 'win32': # pragma: no cover
|
2020-06-18 07:06:33 +00:00
|
|
|
envdir = fr'\\?\{os.path.normpath(envdir)}'
|
2023-03-15 16:39:30 +00:00
|
|
|
- cmd = [sys.executable, '-mnodeenv', '--prebuilt', '--clean-src', envdir]
|
|
|
|
+ cmd = ['@nodeenv@/bin/nodeenv', '--prebuilt', '--clean-src', envdir]
|
|
|
|
if version != C.DEFAULT:
|
|
|
|
cmd.extend(['-n', version])
|
|
|
|
cmd_output_b(*cmd)
|
2020-06-18 07:06:33 +00:00
|
|
|
diff --git a/pre_commit/languages/python.py b/pre_commit/languages/python.py
|
2023-03-15 16:39:30 +00:00
|
|
|
index 976674e..485fe2d 100644
|
2020-06-18 07:06:33 +00:00
|
|
|
--- a/pre_commit/languages/python.py
|
|
|
|
+++ b/pre_commit/languages/python.py
|
2023-03-15 16:39:30 +00:00
|
|
|
@@ -203,7 +203,7 @@ def install_environment(
|
2021-03-12 07:09:13 +00:00
|
|
|
additional_dependencies: Sequence[str],
|
2020-06-18 07:06:33 +00:00
|
|
|
) -> None:
|
2023-03-15 16:39:30 +00:00
|
|
|
envdir = lang_base.environment_dir(prefix, ENVIRONMENT_DIR, version)
|
2021-03-12 07:09:13 +00:00
|
|
|
- venv_cmd = [sys.executable, '-mvirtualenv', envdir]
|
|
|
|
+ venv_cmd = ['@virtualenv@/bin/virtualenv', envdir]
|
2020-06-18 07:06:33 +00:00
|
|
|
python = norm_version(version)
|
2021-03-12 07:09:13 +00:00
|
|
|
if python is not None:
|
|
|
|
venv_cmd.extend(('-p', python))
|