Visual Studio Code launched from command line conf

2020-05-06 08:21发布

问题:

If you launch Visual Studio Code from the command line, entering "code", the command line(terminal) process and the vsc process becoming linked. vsc log entries are written to the terminal. The terminal becomes fragile or unusable. Terminating the terminal also terminates VSC.

This is on Windows 10, VSC v 1.33.1. The VSC installation used default settings. The code.exe file is at C:\Users{userid}\AppData\Local\Programs\Microsoft VS Code\

How can this problem be avoided?

回答1:

The solution is to launch "code.cmd" instead of just "code" (which launches code.exe.)

code.cmd is in the bin folder under the folder holding code.exe.

Both folders are on my PATH, presumably because the installer made it so.