点击查看-》命令面板-》输入setting-》选择首选项,打开设置json
输入以下代码
{
"terminal.integrated.profiles.windows": {
"PowerShell": {
"source": "PowerShell",
"overrideName": true,
"args": ["-NoExit", "/c", "chcp 65001"],
"icon": "terminal-powershell",
"env": {
"TEST_VAR": "value"
}
}
},
"terminal.integrated.defaultProfile.windows": "PowerShell",
"files.encoding": "gb2312",
"files.autoGuessEncoding": true,
}