GitHub Actions: Add yamllint problem matcher (#37468)

* GitHub Actions: Add yamllint problem matcher

* Introduce YAML issue to test problem matcher

* Revert "Introduce YAML issue to test problem matcher"

This reverts commit fa88c9484e.
pull/37497/head
Franck Nijhof 2020-07-05 02:05:14 +02:00 committed by GitHub
parent 6d6188e34d
commit 3eb6e75d3e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 25 additions and 0 deletions

View File

@ -498,6 +498,9 @@ jobs:
run: |
echo "Failed to restore Python virtual environment from cache"
exit 1
- name: Register yamllint problem matcher
run: |
echo "::add-matcher::.github/workflows/matchers/yamllint.json"
- name: Run yamllint
run: |
. venv/bin/activate

View File

@ -0,0 +1,22 @@
{
"problemMatcher": [
{
"owner": "yamllint",
"pattern": [
{
"regexp": "^(.*\\.ya?ml)$",
"file": 1
},
{
"regexp": "^\\s{2}(\\d+):(\\d+)\\s+(error|warning)\\s+(.*?)\\s+\\((.*)\\)$",
"line": 1,
"column": 2,
"severity": 3,
"message": 4,
"code": 5,
"loop": true
}
]
}
]
}