Skip to content

Commit 29060ae

Browse files
authored
Enable problem-matchers in CI (#3480)
1 parent 8271760 commit 29060ae

File tree

2 files changed

+46
-0
lines changed

2 files changed

+46
-0
lines changed

.github/rust-matchers.json

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
{
2+
"problemMatcher": [
3+
{
4+
"owner": "rust-compiler",
5+
"pattern": [
6+
{
7+
"regexp": "^(?:\\x1B\\[[0-9;]*[a-zA-Z])*(warning|warn|error)(\\[(\\S*)\\])?(?:\\x1B\\[[0-9;]*[a-zA-Z])*: (.*?)(?:\\x1B\\[[0-9;]*[a-zA-Z])*$",
8+
"severity": 1,
9+
"message": 4,
10+
"code": 3
11+
},
12+
{
13+
"regexp": "^(?:\\x1B\\[[0-9;]*[a-zA-Z])*\\s+(?:\\x1B\\[[0-9;]*[a-zA-Z])*-->\\s(?:\\x1B\\[[0-9;]*[a-zA-Z])*(\\S+):(\\d+):(\\d+)(?:\\x1B\\[[0-9;]*[a-zA-Z])*$",
14+
"file": 1,
15+
"line": 2,
16+
"column": 3
17+
}
18+
]
19+
},
20+
{
21+
"owner": "rust-formatter",
22+
"pattern": [
23+
{
24+
"regexp": "^(Diff in (\\S+)) at line (\\d+):",
25+
"message": 1,
26+
"file": 2,
27+
"line": 3
28+
}
29+
]
30+
},
31+
{
32+
"owner": "rust-panic",
33+
"pattern": [
34+
{
35+
"regexp": "^.*panicked\\s+at\\s+'(.*)',\\s+(.*):(\\d+):(\\d+)$",
36+
"message": 1,
37+
"file": 2,
38+
"line": 3,
39+
"column": 4
40+
}
41+
]
42+
}
43+
]
44+
}

xtask/src/main.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -344,6 +344,8 @@ fn publish(workspace: &Path, args: PublishArgs) -> Result<()> {
344344
}
345345

346346
fn run_ci_checks(workspace: &Path, args: CiArgs) -> Result<()> {
347+
println!("::add-matcher::.github/rust-matchers.json");
348+
347349
let mut failure = false;
348350
let started_at = Instant::now();
349351

0 commit comments

Comments
 (0)