mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 08:14:42 +04:00
parent
26e60fa333
commit
b81c9802ae
28 changed files with 58 additions and 58 deletions
|
|
@ -49,7 +49,7 @@ def norm_version(version):
|
|||
# If it is in the form pythonx.x search in the default
|
||||
# place on windows
|
||||
if version.startswith('python'):
|
||||
return r'C:\{0}\python.exe'.format(version.replace('.', ''))
|
||||
return r'C:\{}\python.exe'.format(version.replace('.', ''))
|
||||
|
||||
# Otherwise assume it is a path
|
||||
return os.path.expanduser(version)
|
||||
|
|
@ -67,7 +67,7 @@ def install_environment(
|
|||
with clean_path_on_failure(repo_cmd_runner.path(directory)):
|
||||
venv_cmd = [
|
||||
sys.executable, '-m', 'virtualenv',
|
||||
'{{prefix}}{0}'.format(directory)
|
||||
'{{prefix}}{}'.format(directory)
|
||||
]
|
||||
if version != 'default':
|
||||
venv_cmd.extend(['-p', norm_version(version)])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue