goyo wrote: ↑Mon Nov 23, 2020 4:01 pm
I would like to run osdk_build.bat from Microsoft Visual Studio Code,
Code: Select all
{
"version": "2.0.0",
"key": "cmd+shift+R",
"tasks": [
{
"type":"shell",
"label":"build osdk project",
"command": "osdk_build.bat",
}
]
}
but I have this error :
Code: Select all
i have this error message : Code language not supported or defined.
ideas?
Hi Goyo,
I think the error maybe because you have a superfluous comma before a closing brace, so your JSON definition file is incorrect.
If you just remove the comma after "osdk_build.bat" it should work.
Also, I believe the "key" entry is incorrect. It doesn't apply to the "'tasks.json" file as far as I know, but to the "keybindings.json" file. See
https://code.visualstudio.com/docs/edit ... s-to-tasks
Now, as an example here is the (working) "tasks.json" file I use in most of my projects (as a reminder, this file must be placed in a ".vscode" subdirectory at the root of your project directory).
Also note that I renamed the scripts, e.g. I use "build.bat" instead of "osdk_build.bat":
Code: Select all
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "OSDK Build",
"type": "shell",
"command": "build.bat",
"group": {
"kind": "build",
"isDefault": true
},
"problemMatcher": []
},
{
"label": "OSDK Execute",
"type": "shell",
"command": "execute.bat",
"problemMatcher": [],
"group": {
"kind": "execute",
"isDefault": false
}
}
]
}