Description
What problem does this solve or what need does it fill?
It's very common for either typos, cargo fmt
, and/or taplo fmt
to fail during CI, requiring a usually trivial commit where the relevant tool is used. This also occurs when a reviewer suggests changes to a PR, since the suggestion may require formatting changes which are either hard or impossible to include in a suggestion
block.
What solution would you like?
One or more GitHub Actions which can run the relevant linter and create a suggestion which can be applied to a PR. Crucially, this is not an automatic fix for the PR, it just allows the fix to be done entirely from the web or application UI. This is especially helpful for maintainers who have permission to modify PRs, since they could (for example) upstream main, suggest some minor fixes, and then apply suggested formatting changes all in one sitting without switching context.
What alternative(s) have you considered?
Could do nothing. This is an annoyance at most. But if we can automate the process, why not?
Additional context
- An example of this can be found in the Suggest Changes Action.
- CI permissions can be challenging to get right, so I would encourage any CI experts to weigh in on the potential risks of such a bot.