Add “Open with Code” to Context Menu on Windows

DevNotes
By -
0

 Create a new file and name it:

vscode_context_menu.reg



 Paste this content (already adapted to your path)

[code lang="bash"]

Windows Registry Editor Version 5.00


; === Open folder with VS Code ===

[HKEY_CLASSES_ROOT\Directory\shell\Open with Code]

@="Open with Code"

"Icon"="\"C:\\Program Files\\Microsoft VS Code\\Code.exe\""


[HKEY_CLASSES_ROOT\Directory\shell\Open with Code\command]

@="\"C:\\Program Files\\Microsoft VS Code\\Code.exe\" \"%V\""


; === Open folder background with VS Code ===

[HKEY_CLASSES_ROOT\Directory\Background\shell\Open with Code]

@="Open with Code"

"Icon"="\"C:\\Program Files\\Microsoft VS Code\\Code.exe\""


[HKEY_CLASSES_ROOT\Directory\Background\shell\Open with Code\command]

@="\"C:\\Program Files\\Microsoft VS Code\\Code.exe\" \"%V\""

[/code]

Apply it

  1. Double-click the .reg file

  2. Click YesOK

  3. Restart Windows Explorer

Tags:

Post a Comment

0 Comments

Post a Comment (0)
3/related/default