在 Visual Studio 代码中调试时,使用 "Terminal" 而不是 "Debug Console" 作为 I/O 提要

Use "Terminal" instead of "Debug Console" as the I/O feed, when debugging in Visual Studio Code

是否可以使用终端作为调试过程的 I/O 源而不是调试控制台(例如 Nodejs)在 VS 代码上调试 Go 文件?也许是 launch.json 上的特殊配置?

当前行为:

期望的行为:

"console": "integratedTerminal""console": "externalTerminal" 在您的 launch.json 配置中。

这是一个相对较新的功能,已添加到 Go 扩展 v0.31.0(2022 年 1 月)。