C++ in VS Code: Building your Code with CMake

Поділитися
Вставка
  • Опубліковано 3 лют 2025

КОМЕНТАРІ • 47

  • @MikeTwohey
    @MikeTwohey 9 місяців тому +38

    Wow that is complicated! I need a tool for CMake.

  • @HylkeHellinga-r7q
    @HylkeHellinga-r7q 4 дні тому

    Awesome! Exactly what I needed to know!

  • @wesleytaylor-rendal5648
    @wesleytaylor-rendal5648 5 місяців тому +9

    Why don't you give an examlpe with dependencies?

  • @0xeb-
    @0xeb- 7 місяців тому +7

    any hotkey to run instead of clicking the status bar icon?
    why is F5 hotkey wanting to do its own things? is there a way to have the regular "Run" menu use the CMake tooling?

  • @tambow44
    @tambow44 Місяць тому

    Very well presented. Cheers.

  • @gordonelliott7870
    @gordonelliott7870 4 місяці тому +4

    Did I just see the Microsoft Product Manager installing CMake onto a Mac (including the standard GUI way to move to the "Applications" folder, rather specific name used by Apple)?
    (Yes, chose version for "macOS 10.10 or later".)
    (I do appreciate the wide applicability of the tools and showing that on a different system. Just was a bit jarring.)

    • @abc33155
      @abc33155 Місяць тому

      They discontinued Visual Studio for Mac, that’s why she is showing how to use VS Code instead.

  • @vinniciusrosa8284
    @vinniciusrosa8284 Місяць тому

    I noticed I have to understand how json files work. What is it used for originaly and stuff. Thanks. I was stuck at json file part. Thanks for the video.

  • @chulavista5239
    @chulavista5239 3 місяці тому +1

    Since Visual Studio Community Edition is free, what are any good reasons we might wish to develop C++ in VS Code? Just curious.

    • @Vietexa
      @Vietexa Місяць тому

      well, if you want to use a compiler toolchain like GCC or Clang, then you should go with it since Visual Studio uses their own proprietary compiler (MSVC), which is exclusive to windows, not to mention that Visual Studio itself is exclusive to windows too, so if you work on linux or mac then that can't be an option.

    • @Vietexa
      @Vietexa Місяць тому +1

      there are plenty of reasons to go with visual studio code, but there are equally as many not to do so, it's up to your own preference and plans. If you want to make a piece of software that is open source and let other people that don't use windows also work on it, then you can't do it by using Visual Studio for it. If you want things to be served on a plate for you (the same as most IDEs do), then you should go with Visual Studio, if you look for compatibility and making projects that can be developed cross platform while also having more freedom in customization, then go with vs code, visual studio code is not even and IDE, it is a code editor that you can use extensions to extend its functionality (which can bring it close to what an ide can do)

    • @Juke172
      @Juke172 28 днів тому

      I use mac and windows so I don't even use Visual Studio anymore because it's not supported one of them. It's just better to have tools that apply to all the needs and have less hassle(if that is even possible..)

  • @cokpot635
    @cokpot635 2 місяці тому +8

    The irony. Why is microsoft employee using mac??

  • @khalilhashmi7570
    @khalilhashmi7570 4 місяці тому

    I have problem with CMake, when I select the side popup bar for CMake It shows [Target in Preset] for (Build), I couldn't change it to (MyCMakeproject). can you help me?

  • @ignacionr
    @ignacionr 5 місяців тому +3

    CMake has this problem that every feature has a randomly created command name. There is absolutely no norm or reasoning in what are the command names.

  • @sukivirus
    @sukivirus 3 місяці тому

    more cmake tutorials please. sometimes intellisense does not respond if the cpp files are inside nested directory.

  • @williamsf.h.227
    @williamsf.h.227 7 місяців тому

    Can you please provide a class for adding more file to CMAKE in just 2 steps?

  • @sciencejournal8831
    @sciencejournal8831 3 місяці тому

    I want video on setup of c++ and opencv , cmake in vs code editor

  • @Tony-dp1rl
    @Tony-dp1rl 9 місяців тому +19

    I spent over 20 years developing in C++ daily before escaping. For those still trapped, I wish you well.

    • @krishna_o15
      @krishna_o15 9 місяців тому

      😂

    • @blipojones2114
      @blipojones2114 6 місяців тому +1

      Jokes aside, would you flat out just send unsuspecting victims to Rust, Zig, Go?

    • @persimmon2298
      @persimmon2298 5 місяців тому +1

      Which tarpit did you escape to? 😂

    • @MrSparc
      @MrSparc Місяць тому

      Let me guess: You escaped from C++ to Javascript, right? 😂

  • @ChrisBlue4U
    @ChrisBlue4U 3 місяці тому +6

    Even Microsoft staff isn’t using Windows 😂 don’t blame her

  • @josemarcos1519
    @josemarcos1519 9 місяців тому +2

    Hello everyone! I would like to suggest that VSCode have a theme that follows the Windows 11 theme, including the Mica effect on the top menu bar and status bar, as it does in Microsoft Edge.

  • @paulnnamdi4098
    @paulnnamdi4098 5 місяців тому +1

    Nice tutorial. You didn't state the keyboard shortcut you used to enter the Command Palette in Vscode (It is Ctrl + Shift + P). Again at that "Set Build Target" things were a little muddled up, because if you click it, it lists out Presets for you to select from and gives you the option to add a new Preset, but you just entered the name skipping a step and also without stating whether you added an additional Preset.

  • @maciej1214
    @maciej1214 9 місяців тому +1

    How to compile a single cpp file? Many times there is an error that file cannot be compiled.

    • @koraironams4656
      @koraironams4656 8 місяців тому +2

      😂😂

    • @tarik_hello
      @tarik_hello 8 місяців тому

      Hey! This could be due to the compiler you are trying to use. If you are trying to compile a C++ file, make sure you are using a g++ compiler or its equivalent.

    • @razorblade413
      @razorblade413 7 місяців тому

      that's why i prefer coding in java...no bs with unnecessary files. Just straight to develop an app.

    • @razorblade413
      @razorblade413 7 місяців тому

      i wanted to learn c++ from scratch, but after seeing that i need to download compilers, cmake, and whatever other tools, instead of just using a IDE and make a simple f project, i prefer to quit this. Never again!

    • @m____s
      @m____s 7 місяців тому

      @@razorblade413 What do you use instead?

  • @alexanderkuznetsov634
    @alexanderkuznetsov634 9 місяців тому

    Thank you

  • @mervindaly371
    @mervindaly371 9 місяців тому +1

    Love your video❤

  • @akompsupport
    @akompsupport 9 місяців тому

    Nice! 🎂

  • @captainobvious7898
    @captainobvious7898 6 днів тому

    How to do this with remote development? CMake tools button disappears if your project is remote