mirror of
https://github.com/pypa/pip
synced 2023-12-13 21:30:23 +01:00
Reverted GIT__CMD change;
Changed pip to use suprocess instead of execv for venv restart.
This commit is contained in:
parent
5e08433978
commit
70e1539c05
1 changed files with 8 additions and 3 deletions
11
pip.py
11
pip.py
|
@ -52,7 +52,10 @@ pypi_url = "http://pypi.python.org/simple"
|
|||
default_timeout = 15
|
||||
|
||||
# Choose a Git command based on platform.
|
||||
GIT_CMD = 'git'
|
||||
if sys.platform == 'win32':
|
||||
GIT_CMD = 'git.cmd'
|
||||
else:
|
||||
GIT_CMD = 'git'
|
||||
|
||||
## FIXME: this shouldn't be a module setting
|
||||
default_vcs = None
|
||||
|
@ -956,8 +959,10 @@ def restart_in_venv(venv, args):
|
|||
base = os.path.dirname(os.path.dirname(python))
|
||||
file = __file__
|
||||
if file.endswith('.pyc'):
|
||||
file = file[:-1]
|
||||
os.execv(python, [python, file] + args + [base, '___VENV_RESTART___'])
|
||||
file = file[:-1]
|
||||
call_subprocess([python, file] + args + [base, '___VENV_RESTART___'])
|
||||
sys.exit(0)
|
||||
#~ os.execv(python, )
|
||||
|
||||
class PackageFinder(object):
|
||||
"""This finds packages.
|
||||
|
|
Loading…
Reference in a new issue