Yas*_*tal 4 visual-studio-code
我在VS Code实例中打开了两个文件夹。
例如(文件夹名称):A和B
我想在VS Code的新实例中打开文件夹B,但是没有通过右键单击该文件夹打开的选项。
甚至Atom都可以选择在新实例中打开文件夹。
小智 7
您可以通过File> New window或ctrl + shift + n进入新窗口,然后在其中打开第二个文件夹。
或“ window.openFoldersInNewWindow”设置:
// Controls if folders should open in a new window or replace the last active window.
// - default: folders will open in a new window unless a folder is picked from within the application (e.g. via the File menu)
// - on: folders will open in a new window
// - off: folders will replace the last active window
// Note that there can still be cases where this setting is ignored (e.g. when using the -new-window or -reuse-window command line option).
"window.openFoldersInNewWindow": "default",
Run Code Online (Sandbox Code Playgroud)
小智 7
创建一个注册表文件,例如 OpenOnRightClick.reg
将这些行添加到文件中:
Windows Registry Editor Version 5.00
; Open files
[HKEY_CLASSES_ROOT\*\shell\Open with VS Code]
@="Edit with VS Code"
"Icon"="C:\\Users\\xx\\AppData\\Local\\Programs\\Microsoft VS Code\\Code.exe,0"
[HKEY_CLASSES_ROOT\*\shell\Open with VS Code\command]
@="\"C:\\Users\\xx\\AppData\\Local\\Programs\\Microsoft VS Code\\Code.exe\" \"%1\""
; This will make it appear when you right click ON a folder
; The "Icon" line can be removed if you don't want the icon to appear
[HKEY_CLASSES_ROOT\Directory\shell\vscode]
@="Open Folder as VS Code Project"
"Icon"="\"C:\\Users\\xx\\AppData\\Local\\Programs\\Microsoft VS Code\\Code.exe\",0"
[HKEY_CLASSES_ROOT\Directory\shell\vscode\command]
@="\"C:\\Users\\xx\\AppData\\Local\\Programs\\Microsoft VS Code\\Code.exe\" \"%1\""
; This will make it appear when you right click INSIDE a folder
; The "Icon" line can be removed if you don't want the icon to appear
[HKEY_CLASSES_ROOT\Directory\Background\shell\vscode]
@="Open Folder as VS Code Project"
"Icon"="\"C:\\Users\\xx\\AppData\\Local\\Programs\\Microsoft VS Code\\Code.exe\",0"
[HKEY_CLASSES_ROOT\Directory\Background\shell\vscode\command]
@="\"C:\\Users\\xx\\AppData\\Local\\Programs\\Microsoft VS Code\\Code.exe\" \"%V\""
Run Code Online (Sandbox Code Playgroud)
根据您的安装目录更改 Visual Studio 代码的位置 现在只需双击 OpenOnRightClick.reg 文件,确认是否询问!全部完成 !在您右键单击时,您将有一个打开的代码选项。
让我们让它变得非常简单
就是这样。新的空白窗口打开了新项目。
下面讨论另一种方式
vscode. 在文件位置,输入 URL cmdcode .vscode窗口中打开。| 归档时间: |
|
| 查看次数: |
9107 次 |
| 最近记录: |