mirror of
https://github.com/kennethreitz/pipenv.git
synced 2026-06-05 22:50:18 +00:00
Fixed handling of .py files on Windows
This commit is contained in:
+4
-3
@@ -731,10 +731,11 @@ def pip_download(package_name):
|
||||
|
||||
|
||||
def which(command):
|
||||
if os.name == 'nt' and not command.endswith('.py'):
|
||||
if os.name == 'nt':
|
||||
if command.endswith('.py'):
|
||||
return os.sep.join([project.virtualenv_location] + ['Scripts\{0}'.format(command)])
|
||||
return os.sep.join([project.virtualenv_location] + ['Scripts\{0}.exe'.format(command)])
|
||||
else:
|
||||
return os.sep.join([project.virtualenv_location] + ['bin/{0}'.format(command)])
|
||||
return os.sep.join([project.virtualenv_location] + ['bin/{0}'.format(command)])
|
||||
|
||||
|
||||
def which_pip(allow_global=False):
|
||||
|
||||
Reference in New Issue
Block a user