I use VS code on Mac OS for programming with C++. Pressing the run triangle button successfully compiles the code and it starts running in the Debug Console automatically. I can’t use the Debug Console, because it doesn’t accept keyboard entries in run-time for some reason. Is it possible to automatically run the code in the integrated Terminal instead, when pressing the run button?
Do I need to configure the launch.json?
Thanks
Question posted in Visual Studio Code
View the official documentation.
View the official documentation.
2
Answers
One workaround is to create inside the launch.json a configuration with the attribute.
It doesn't solve the problem completely, but at least one can interact with the keyboard in runtime and also doesn't have to start the program via typing.
Yes. There’s an attribute
console
that can be set tointegratedTerminal
.Depending on the extension you are using, you may need to create `.vscode/launch.json’ manually. Sooner or later you may need a custom launch file anyway (e.g. when passing arguments).