首先在页面上新建个文本文件,然后改名和后缀为 add.reg
然后把下面的代码放到里面去,修改路径,然后直接运行就可以了
(路径就是vscode安装的目录)
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT*shellVSCode]
@="Open with Code"
"Icon"="C:\Program Files (x86)\Microsoft VS Code\Code.exe"
[HKEY_CLASSES_ROOT*shellVSCodecommand]
@=""C:\Program Files (x86)\Microsoft VS Code\Code.exe" "%1""
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOTDirectoryshellVSCode]
@="Open with Code"
"Icon"="C:\Program Files (x86)\Microsoft VS Code\Code.exe"
[HKEY_CLASSES_ROOTDirectoryshellVSCodecommand]
@=""C:\Program Files (x86)\Microsoft VS Code\Code.exe" "%V""
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOTDirectoryBackgroundshellVSCode]
@="Open with Code"
"Icon"="C:\Program Files (x86)\Microsoft VS Code\Code.exe"
[HKEY_CLASSES_ROOTDirectoryBackgroundshellVSCodecommand]
@=""C:\Program Files (x86)\Microsoft VS Code\Code.exe" "%V""