Well, I don’t think the plugin actually handles parsing the error messages. This could be something we might incorporate into that plugin.
Right now, however, in all of my projects I have a file <project>/.vscode/tasks.json where I keep this.
Here’s what my tasks.json file looks like for my purescript code:
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"problemMatcher": {
"owner": "purescript",
"fileLocation": ["relative", "${workspaceFolder}"],
"pattern": [
{
"regexp":
"at (.*\\.purs) line (\\d+), column (\\d+) - line (\\d+), column (\\d+).*",
"file": 1,
"line": 2,
"column": 3,
"endLine": 4,
"endColumn": 5
},
{
"regexp": "^$"
},
{
"regexp": "^(.*)$",
"message": 1
}
]
},
"tasks": [
{
"label": "configure",
"type": "shell",
"command": "npm",
"args": ["install"]
},
{
"label": "run",
"type": "shell",
"command": "npm",
"args": ["start"]
},
{
"label": "build",
"type": "shell",
"command": "npm",
"args": ["run-script", "build"],
"group": {
"kind": "build",
"isDefault": true
}
},
{
"label": "test",
"type": "shell",
"command": "npm",
"args": ["test"],
"group": {
"kind": "test",
"isDefault": true
}
}
]
}
I have a similar tasks.json file for Haskell, since I had to write a custom problem matcher for Haskell too.