nel*_*2tm 57 windows-10 windows-10-v1703
自创作者更新(2017-04)以来,按住 Shift 键右键单击资源管理器中的空白处会显示“使用 PowerShell 打开”而不是“使用命令提示符打开”。我怎样才能让旧的行为回到显示“用命令提示符打开”的地方?
我尝试将设置“右键单击开始菜单或按 Windows + X 时显示 PowerShell 而不是命令提示符”更改为关闭,但这并没有更改 shift+右键单击菜单。
mag*_*981 62
打开 regedit.exe,转到HKEY_CLASSES_ROOT\Directory\shell\cmd,获取密钥的所有权,添加您的用户帐户完全权限并将 DWORD 的名称从 更改HideBasedOnVelocityId为ShowBasedOnVelocityId以再次启用命令提示符条目。
或应用Andrew Richards 调整以显示(cmd 和 PowerShell,也有条目以提升(以管理员身份运行)版本),
通过导入他的 .reg 文件(创建一个新的 txt 文件,粘贴内容并将文件扩展名重命名为 reg):
Windows Registry Editor Version 5.00
; Command Prompt
[HKEY_CLASSES_ROOT\Directory\shell\01MenuCmd]
"MUIVerb"="Command Prompts"
"Icon"="cmd.exe"
"ExtendedSubCommandsKey"="Directory\\ContextMenus\\MenuCmd"
[HKEY_CLASSES_ROOT\Directory\background\shell\01MenuCmd]
"MUIVerb"="Command Prompts"
"Icon"="cmd.exe"
"ExtendedSubCommandsKey"="Directory\\ContextMenus\\MenuCmd"
[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuCmd\shell\open]
"MUIVerb"="Command Prompt"
"Icon"="cmd.exe"
[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuCmd\shell\open\command]
@="cmd.exe /s /k pushd \"%V\""
[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuCmd\shell\runas]
"MUIVerb"="Command Prompt Elevated"
"Icon"="cmd.exe"
"HasLUAShield"=""
[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuCmd\shell\runas\command]
@="cmd.exe /s /k pushd \"%V\""
; PowerShell
[HKEY_CLASSES_ROOT\Directory\shell\02MenuPowerShell]
"MUIVerb"="PowerShell Prompts"
"Icon"="powershell.exe"
"ExtendedSubCommandsKey"="Directory\\ContextMenus\\MenuPowerShell"
[HKEY_CLASSES_ROOT\Directory\background\shell\02MenuPowerShell]
"MUIVerb"="PowerShell Prompts"
"Icon"="powershell.exe"
"ExtendedSubCommandsKey"="Directory\\ContextMenus\\MenuPowerShell"
[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuPowerShell\shell\open]
"MUIVerb"="PowerShell"
"Icon"="powershell.exe"
[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuPowerShell\shell\open\command]
@="powershell.exe -noexit -command Set-Location '%V'"
[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuPowerShell\shell\runas]
"MUIVerb"="PowerShell Elevated"
"Icon"="powershell.exe"
"HasLUAShield"=""
[HKEY_CLASSES_ROOT\Directory\ContextMenus\MenuPowerShell\shell\runas\command]
@="powershell.exe -noexit -command Set-Location '%V'"
; Ensure OS Entries are on the Extended Menu (Shift-Right Click)
[HKEY_CLASSES_ROOT\Directory\shell\cmd]
"Extended"=""
[HKEY_CLASSES_ROOT\Directory\background\shell\cmd]
"Extended"=""
[HKEY_CLASSES_ROOT\Directory\shell\Powershell]
"Extended"=""
[HKEY_CLASSES_ROOT\Directory\background\shell\Powershell]
"Extended"=""
Run Code Online (Sandbox Code Playgroud)
Rap*_*ael 21
作为其他答案的快速替代方法,您可以cmd在资源管理器的地址栏中键入以打开cd指向当前目录的命令提示符。(如果您更喜欢键盘侠,可以使用Ctrl + L快捷方式聚焦地址栏,然后键入cmd。)
这也适用powershell。
编辑(2021-08-02):正如@pj.dewitte 指出的,您可能需要使用.exe扩展名(即cmd.exe,powershell.exe)。
这非常容易实现
- 在任务栏和开始菜单属性窗口中,转到导航选项卡并取消选中将命令提示符替换为 Windows PowerShell选项。
- 单击应用以使更改生效。
资料来源:
额外来源:
| 归档时间: |
|
| 查看次数: |
80936 次 |
| 最近记录: |