skip to Main Content

I am trying to set up VSCode as a C/C++ development environment using gcc/g++ installed from homebrew on my MacBook.

It all works fine. When I run a file, it finds gcc which I installed with homebrew. However, the output is shown in the debug console instead of in the terminal which I would prefer:
enter image description here

I tried to look online, but I couldn’t find any way to do it. In addition, on my Windows desktop, I followed the same procedure to set up VSCode and it did run in the integrated terminal.

Why does it run in the terminal on Windows by default and not on Mac and how can I configure it to run in a terminal?

3

Answers


  1. Maybe you set the debug console as the default option. You can type "ctrl+shift+P" and then choose launch.json. Delete the line "console": "internalConsole"

    Login or Signup to reply.
  2. File -> Preferences -> Settings -> Extensions -> Run Code Config -> Run In Terminal

    This should work ^^

    Login or Signup to reply.
  3. You could run it from the terminal.
    You can open a terminal via ^⇧`
    This works great for me.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search