You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We could use our restyled diff(s) to make comments via the GitHub API to "suggest changes" on the PR to fix style.
This sounds absolutely ideal:
You can see individual fixes
They can be batched and merged automatically as a group
No need for PRs or back-comments or any of that
However, there are limitations and downsides that stem from the fact that a suggested change is very oriented around suggesting a different line for one added line. The first step here is to get specific about those limitations and figure out how they may impact the 80% case of Restyle fixes.
The text was updated successfully, but these errors were encountered:
I like this idea, here are some thoughts on heuristics:
Use suggest changes only if
less than a given percentage of modified lines are affected.
less than a given number of adjacent lines are affected.
Use a github comment with a patch if the diff total is less than some number of lines.
Use a PR otherwise.
You could make those things configurable. Most of the time I find that it's 1-2 lines of diff from the restyler, and having a github comment or suggestion is less clutter than a whole PR. The PR gives you a nice workflow where you can just pull the changes from there from the command line, but it's quite a lot of email spam, because the restyled PR doesn't thread with the original.
We could use our restyled diff(s) to make comments via the GitHub API to "suggest changes" on the PR to fix style.
This sounds absolutely ideal:
However, there are limitations and downsides that stem from the fact that a suggested change is very oriented around suggesting a different line for one added line. The first step here is to get specific about those limitations and figure out how they may impact the 80% case of Restyle fixes.
The text was updated successfully, but these errors were encountered: