-
Notifications
You must be signed in to change notification settings - Fork 596
Description
GitHub Actions have a feature with quite hidden documentation: problem matchers. These allow defining regular expressions for compiler warnings/errors so that GitHub can automatically annotate the corresponding code changes in PRs with these warnings or errors.
We should evaluate adding these for the compilers we use in our builds, i.e. GCC and MSVC (and maybe clang?). Having this could be a useful tool on the way to fewer (ideally zero) compiler warnings by ensuring that it's hard to miss if new warnings are introduced.
There are existing actions for this:1
- https://github.com/ammaraskar/gcc-problem-matcher
- https://github.com/ammaraskar/msvc-problem-matcher
Footnotes
-
Given that the relevant part is a JSON file a few lines long + emitting a magic
::
-prefixed line in the job output, we might consider just adding that the JSON files and a simpleecho
statement to our jobs. These actions currently use Node 20, GitHub seems to move to Node 24 for actions, I have no idea if this will become a problem, a simpleecho
command would just continue to work. ↩