Changing the default path of Visual Studio Code's integrated terminal

后端 未结 6 508
不知归路
不知归路 2020-12-24 13:07

I\'m trying to change the default path of the integrated terminal in Visual Studio Code, but I\'m not sure how to. I do know how to change it in the windows command prompt,

6条回答
  •  -上瘾入骨i
    2020-12-24 14:08

    As others have already explained, you can add a setting to change the default folder for your integrated terminal to start in. This setting also accepts Visual Studio Code variables, so to make a relative path from the root folder of your workspace you can use ${workspaceFolder}.

    For example, for your terminal to always start in the subfolder mystart, your setting would be:

    "terminal.integrated.cwd": "${workspaceFolder}/mystart"
    

提交回复
热议问题