mirror of
https://github.com/kennethreitz/pipenv.git
synced 2026-06-05 22:50:18 +00:00
Merge pull request #1715 from pypa/pwsh-support
Support Powershell Core (pwsh.exe) on Windows
This commit is contained in:
@@ -14,7 +14,7 @@ from ctypes.wintypes import DWORD, LONG
|
||||
|
||||
ERROR_NO_MORE_FILES = 18
|
||||
INVALID_HANDLE_VALUE = c_void_p(-1).value
|
||||
SHELL_NAMES = ['cmd', 'powershell', 'cmder']
|
||||
SHELL_NAMES = ['cmd', 'powershell', 'pwsh', 'cmder']
|
||||
|
||||
class PROCESSENTRY32(Structure):
|
||||
_fields_ = [
|
||||
|
||||
@@ -195,7 +195,7 @@ def shell(env, cwd=None):
|
||||
env = str(env)
|
||||
shell = _detect_shell()
|
||||
shell_name = Path(shell).stem
|
||||
if shell_name not in ('Cmder', 'bash', 'elvish', 'powershell', 'klingon', 'cmd'):
|
||||
if shell_name not in ('Cmder', 'bash', 'elvish', 'powershell', 'pwsh', 'klingon', 'cmd'):
|
||||
# On Windows the PATH is usually set with System Utility
|
||||
# so we won't worry about trying to check mistakes there
|
||||
shell_check = (sys.executable + ' -c "from pipenv.patched.pew.pew import '
|
||||
|
||||
Reference in New Issue
Block a user