右键快速打开命令行

1、新建一个openCommand.txt文件,将下列代码输入其中

Windows Registry Editor Version 5.00
 
[HKEY_CLASSES_ROOT\Directory\shell\OpenCmdHere]
@="open command window here"
"Icon"="cmd.exe"
 
[HKEY_CLASSES_ROOT\Directory\shell\OpenCmdHere\command]
@="cmd.exe /s /k pushd "%V""
 
[HKEY_CLASSES_ROOT\Directory\Background\shell\OpenCmdHere]
@="open command window here"
"Icon"="cmd.exe"
 
[HKEY_CLASSES_ROOT\Directory\Background\shell\OpenCmdHere\command]
@="cmd.exe /s /k pushd \"%V\""
 
[HKEY_CLASSES_ROOT\Drive\shell\OpenCmdHere]
@="open command window here"
"Icon"="cmd.exe"
 
[HKEY_CLASSES_ROOT\Drive\shell\OpenCmdHere\command]
@="cmd.exe /s /k pushd \"%V\""
 
[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\OpenCmdHere]
@="open command window here"
"Icon"="cmd.exe"
 
[HKEY_CLASSES_ROOT\LibraryFolder\background\shell\OpenCmdHere\command]
@="cmd.exe /s /k pushd \"%V\""

2、保存后,修改文件类型为.reg格式,双击运行,实现效果如下:

发布了63 篇原创文章 · 获赞 95 · 访问量 41万+

猜你喜欢

转载自blog.csdn.net/zwl1584671413/article/details/102720261