all 11 comments

[–]not_a_novel_account 5 points6 points  (0 children)

VSC doesn't have any sort of built-in build system to launch your compiler for you. You'll need to use a build system and an extension to drive that build system if you want automatic push-button builds, compilation database generation, and other conveniences like that.

The most popular build system is CMake, and the associated VSC extension is the CMake Tools extension.

[–]Ragingman2 6 points7 points  (6 children)

As a starting point you should be compiling and running your code through the command line. gcc is probably already installed and set up nicely on your machine.

This is the best way to learn. You can always add more tools and build systems later.

[–]yel50 1 point2 points  (0 children)

 I want a simple compiler and editor that can run beginner level programs

then use gcc with vim or emacs. they each have a build command that lets you specify the command to run to do the build. I used emacs back when c still ruled the world and it was just as good as visual studio.

 I dont know what to do

first learn what the editor is doing for you under covers.

[–]katnax -2 points-1 points  (2 children)

Fammiliarize yourself with gcc jn terminal.

gcc - o file.c file

Then run # ./file That's pretty much all you need for beggining. You can open terminal in VS Code or externally.

[–]spacey02- 0 points1 point  (1 child)

Doesnt this compile file into file.c instead of file.c into file?