这里写自定义目录标题
Windows系统在鼠标右键添加CMD命令
手动方式添加
1.WIN+R,输入regedit
,依次展开HKEY_CLASSES_ROOT\DesktopBackground\Shell\cmd
,添加cmd项,修改默认值为 cmd.exe /s /k pushd "%V"
2. 右键目录时菜单显示进入命令行选项
依次展开 HKEY_CLASSES_ROOT\Directory\shell\cmd\command
,添加cmd-command,修改默认值
脚本方式添加
添加CMD到右键菜单脚本
Open_Command_Admin.reg
Windows Registry Editor Version 5.00
[-HKEY_CLASSES_ROOT\Directory\shell\runas]
[HKEY_CLASSES_ROOT\Directory\shell\runas]
@="Open_Command_Admin"
"HasLUAShield"=""
[HKEY_CLASSES_ROOT\Directory\shell\runas\command]
@="cmd.exe /s /k pushd \"%V\""
[-HKEY_CLASSES_ROOT\Directory\Background\shell\runas]
[HKEY_CLASSES_ROOT\Directory\Background\shell\runas]
@="Open_Command_Admin"
"HasLUAShield"=""
[HKEY_CLASSES_ROOT\Directory\Background\shell\runas\command]
@="cmd.exe /s /k pushd \"%V\""
[-HKEY_CLASSES_ROOT\Drive\shell\runas]
[HKEY_CLASSES_ROOT\Drive\shell\runas]
@="Open_Command_Admin"
"HasLUAShield"=""
[HKEY_CLASSES_ROOT\Drive\shell\runas\command]
@="cmd.exe /s /k pushd \"%V\""
[-HKEY_CLASSES_ROOT\LibraryFolder\background\shell\runas]
[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\runas]
"HasLUAShield"=""
@="Open_Command_Admin"
[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\runas\command]
卸载右键CMD菜单脚本
Remove_Command_Admin.reg
Windows Registry Editor Version 5.00
[-HKEY_CLASSES_ROOT\Directory\shell\runas]
[-HKEY_CLASSES_ROOT\Directory\Background\shell\runas]
[-HKEY_CLASSES_ROOT\Drive\shell\runas]
[-HKEY_CLASSES_ROOT\LibraryFolder\background\shell\runas]
~