tasks.json
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "build",
"type": "shell",
"command": "crystal",
"args": [
"build",
"${workspaceRoot}/src/${workspaceRootFolderName}.cr"
],
"group": {
"kind": "build",
"isDefault": true
},
"presentation": {
"panel": "new"
},
"problemMatcher": {
"owner": "crystal",
"fileLocation": [
"relative",
"${workspaceRoot}"
],
"pattern": {
"regexp": "^(.+):(\\d+):(\\d+):\\s+(\\d+):(\\d+)\\s+(warning|error):\\s+(.*)$",
"file": 1,
"line": 2,
"column": 3,
"endLine": 4,
"endColumn": 5,
"severity": 6,
"message": 7
}
}
},
{
"label": "run",
"type": "shell",
"command": "crystal",
"args": [
"run",
"${workspaceRoot}/src/${workspaceRootFolderName}.cr"
],
"presentation": {
"panel": "new"
},
"problemMatcher": []
},
{
"label": "test",
"type": "shell",
"command": "crystal spec",
"group": {
"kind": "test",
"isDefault": true
},
"presentation": {
"panel": "new"
},
"problemMatcher": [
{
"owner": "crystal",
"fileLocation": [
"relative",
"${workspaceRoot}"
],
"pattern": {
"regexp": "^(.+):(\\d+):(\\d+):\\s+(\\d+):(\\d+)\\s+(warning|error):\\s+(.*)$",
"file": 1,
"line": 2,
"column": 3,
"endLine": 4,
"endColumn": 5,
"severity": 6,
"message": 7
}
},
{
"owner": "crystal",
"fileLocation": [
"relative",
"${workspaceRoot}"
],
"severity": "error",
"pattern": {
"regexp": "^.*panicked\\s+at\\s+'(.*)',\\s+(.*):(\\d+)$",
"message": 1,
"file": 2,
"line": 3
}
}
]
}
]
}