VSCode: clear integrated terminal when debug starts
Answer a question
when using "console": "integratedTerminal" in a launch.json the program output is redirected to the integrated terminal. However, after terminating a debug session and starting another one, the terminal is re-used which can be pretty annoying.
I have not found a way to make VSCode clear the terminal -- it is possible to clear the panel in tasks.json with the clear: true property, this however only works for tasks such as the build task but has no effect on the debug panel.
Help is greatly appreciated.
Thanks in advance
-Simon
Answers
There is a new setting due in v1.55:
debug.terminal.clearBeforeReusing
Some debug extension allow to launch debuggees in VS Code's integrated terminal. In order keep the number of integrated terminals small, VS Code tries to reuse a terminal if it is not blocked by a still running command. A consequence of this approach is that previous commands and program output will remain visible in the terminal which is sometimes confusing.
In this release we've introduced a new feature to automatically clear the integrated terminal before starting a new debug session. The feature is controlled by the new setting
debug.terminal.clearBeforeReusing.
from https://github.com/microsoft/vscode-docs/blob/vnext/release-notes/v1_55.md#new-setting-for-clearing-a-terminal-before-launching-a-debuggee
更多推荐
所有评论(0)