美文网首页IT🐶
Anaconda安装VSCode丢失右键菜单功能

Anaconda安装VSCode丢失右键菜单功能

作者: 爱折腾的大懒猪 | 来源:发表于2019-03-14 00:20 被阅读0次

使用Anaconda自动安装了VS Code。 然而,发现右键没有了VS Code的功能。。。

VS code安装时关键步骤

默认下, Anaconda安装的VS Code在C:/Program Files里面。上网找了一下右键菜单的方法,和之前一样都是注册表修改。

解决的方式是可以自己重新安装, 然后选中选项。

或者在桌面新建记事本文件,然后打开添加如下代码:

Windows Registry Editor Version 5.00 
 
; Open files 
[HKEY_CLASSES_ROOT\*\shell\Open with VS Code] 
@="Edit with VS Code" 
"Icon"="C:\\Program Files\\Microsoft VS Code\\Code.exe,0" 
 
[HKEY_CLASSES_ROOT\*\shell\Open with VS Code\command] 
@="\"C:\\Program Files\\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:\\Program Files\\Microsoft VS Code\\Code.exe\",0" 
 
[HKEY_CLASSES_ROOT\Directory\shell\vscode\command] 
@="\"C:\\Program Files\\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:\\Program Files\\Microsoft VS Code\\Code.exe\",0" 
 
[HKEY_CLASSES_ROOT\Directory\Background\shell\vscode\command] 
@="\"C:\\Program Files\\Microsoft VS Code\\Code.exe\" \"%V\"" 

将其另存为vsCodeOpenFolder.reg文件

注意:VS Code的安装路径这里使用的是默认的“C:\Program Files\Microsoft VS Code\” 你要换成你安装的路径才对。

然后双击这个文件就行了, 如果有问题就以管理员的身份运行。

相关文章

网友评论

    本文标题:Anaconda安装VSCode丢失右键菜单功能

    本文链接:https://www.haomeiwen.com/subject/obsapqtx.html