Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions .github/tsc.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,15 @@
"owner": "tsc",
"pattern": [
{
"regexp": "^(?:\\s+\\d+\\>)?([^\\s].*)\\((\\d+|\\d+,\\d+|\\d+,\\d+,\\d+,\\d+)\\)\\s*:\\s+(error|warning|info)\\s+(\\w{1,2}\\d+)\\s*:\\s*(.*)$",
"regexp": "^([^\\s].*)[\\(:](\\d+)[,:](\\d+)(?:\\):\\s+|\\s+-\\s+)(error|warning|info)\\s+TS(\\d+)\\s*:\\s*(.*)$",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be good to add a unit test that loads the regexp and processes it against a line, asserts expected match groups

I'm worried if this change regresses something, at least we have a baseline unit test suite going forward.

Also i'm curious how this compares to vscode's built-in tsc problem matcher or their tsc-watch problem matcher. I briefly looked, but wan't able to find those built-in regexps in their repo.

Copy link
Member

@bryanmacfarlane bryanmacfarlane Feb 17, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ericsciple looks like tests were added below at your request. have a quick look

"file": 1,
"location": 2,
"severity": 3,
"code": 4,
"message": 5
"line": 2,
"column": 3,
"severity": 4,
"code": 5,
"message": 6
}
]
}
]
}
}