I configured the Task.json file .
Here is my task.json file. (before running the task) I created 2 tasks, one for building the CPP file and another for simply running it on the terminal.
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "run",
"type": "shell",
"command": "c:/Users/anime/OneDrive/Documents/countbrac/animesh.exe"
},
{
"label": "Build",
"type": "shell",
"command": "g++",
"args": [
"main.cpp",
"-o",
"animesh"
],
"dependsOn": [
"run"
]
},
]
}
After Running the Task.json file, my task.json file had some alterations(i didn't it, most probably IntelliSense xd). Out of nowhere, My task.json had a new task with the label: shell.
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "run",
"type": "shell",
"command": "c:/Users/anime/OneDrive/Documents/countbrac/animesh.exe"
},
{
"label": "Build",
"type": "shell",
"command": "g++",
"args": [
"main.cpp",
"-o",
"animesh"
],
"dependsOn": [
"run"
]
},
{
"type": "shell",
"label": "cpp.exe build active file",
"command": "C:\\MinGW\\bin\\cpp.exe",
"args": [
"-g",
"${file}",
"-o",
"${fileDirname}\\${fileBasenameNoExtension}.exe"
],
"options": {
"cwd": "C:\\MinGW\\bin"
},
"problemMatcher": [
"$gcc"
],
"group": "build"
}
]
}
So asking why my task.json file was altered, what for? it seems the third task is for building the CPP file but I have already made a task for that then why a new one?