mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-01-27 19:38:35 -06:00
Use pipes.quote for executable path
This commit is contained in:
@@ -3,6 +3,7 @@ from __future__ import unicode_literals
|
||||
|
||||
import io
|
||||
import os.path
|
||||
import pipes
|
||||
import sys
|
||||
|
||||
from pre_commit import output
|
||||
@@ -68,7 +69,7 @@ def install(
|
||||
|
||||
skip_on_missing_conf = 'true' if skip_on_missing_conf else 'false'
|
||||
contents = io.open(resource_filename('hook-tmpl')).read().format(
|
||||
sys_executable=sys.executable,
|
||||
sys_executable=pipes.quote(sys.executable),
|
||||
hook_type=hook_type,
|
||||
hook_specific=hook_specific_contents,
|
||||
config_file=runner.config_file,
|
||||
|
||||
Reference in New Issue
Block a user