66 lines
2.8 KiB
Plaintext
66 lines
2.8 KiB
Plaintext
{
|
|
"$schema": "https://raw.githubusercontent.com/oasis-tcs/sarif-spec/master/Schemata/sarif-schema-2.1.0.json",
|
|
"version": "2.1.0",
|
|
"runs": [
|
|
{
|
|
"tool": {
|
|
"driver": {
|
|
"name": "GitHub Actions lint",
|
|
"version": {{ getVersion | json }},
|
|
"informationUri": "https://github.com/rhysd/actionlint",
|
|
"rules": [
|
|
{{$first := true}}
|
|
{{range $ := allKinds }}
|
|
{{if $first}}{{$first = false}}{{else}},{{end}}
|
|
{
|
|
"id": {{json $.Name}},
|
|
"name": {{$.Name | toPascalCase | json}},
|
|
"defaultConfiguration": {
|
|
"level": "error"
|
|
},
|
|
"properties": {
|
|
"description": {{json $.Description}},
|
|
"queryURI": "https://github.com/rhysd/actionlint/blob/main/docs/checks.md"
|
|
},
|
|
"fullDescription": {
|
|
"text": {{json $.Description}}
|
|
},
|
|
"helpUri": "https://github.com/rhysd/actionlint/blob/main/docs/checks.md"
|
|
}
|
|
{{end}}
|
|
]
|
|
}
|
|
},
|
|
"results": [
|
|
{{$first := true}}
|
|
{{range $ := .}}
|
|
{{if $first}}{{$first = false}}{{else}},{{end}}
|
|
{
|
|
"ruleId": {{json $.Kind}},
|
|
"message": {
|
|
"text": {{json $.Message}}
|
|
},
|
|
"locations": [
|
|
{
|
|
"physicalLocation": {
|
|
"artifactLocation": {
|
|
"uri": {{json $.Filepath}},
|
|
"uriBaseId": "%SRCROOT%"
|
|
},
|
|
"region": {
|
|
"startLine": {{$.Line}},
|
|
"startColumn": {{$.Column}},
|
|
"endColumn": {{$.EndColumn}},
|
|
"snippet": {
|
|
"text": {{json $.Snippet}}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
{{end}}
|
|
]
|
|
}
|
|
]
|
|
} |