Description
I start to use VS Code. I followed "https://code.visualstudio.com/docs/cpp/config-mingw" but when I choose Ctrl+Shift+B or from the Terminal main menu Run Build Task. I take error . " Cannot build and debug because the active file is not a C or C++ source file.
The terminal process failed to launch (exit code: -1). "
My task.json config.
{ "version": "2.0.0", "tasks": [ { "type": "cppbuild", "label": "C/C++: g++.exe build active file", "command": "C:\\msys64\\mingw64\\bin\\g++.exe", "args": [ "-fdiagnostics-color=always", "-g", "${file}", "-o", "${fileDirname}\\${fileBasenameNoExtension}.exe" ], "options": { "cwd": "${fileDirname}" }, "problemMatcher": [ "$gcc" ], "group": { "kind": "build", "isDefault": true }, "detail": "compiler: C:\\msys64\\mingw64\\bin\\g++.exe" } ] }