-
Notifications
You must be signed in to change notification settings - Fork 925
Tracking issue: check
write mode follow-up
#2536
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hey, I'd like to help with this--should I just start working on a PR? |
Oh whoops, never mind, just noticed #2539! |
@toolness There are lot of low-hanging fruit in my PR! If you've got the time/bandwidth, I'd love to get feedback on some of my design decisions, particularly how I pass around (Apologies if I broke some social rule I'm unaware of...) |
Hi @toolness thanks for your interest, but yeah it looks like someone already started on this. If you want another way to get stuck into rustfmt, #2531 might be good - it is not small or easy, but it doesn't require much knowledge of rustfmt - it is essentially refactoring to remove code dup, but in a non-trivial way. If that sounds interesting, I can provide instructions over on that issue. |
Sounds good @davidbarsky! I still consider myself fairly inexperienced in Rust, but I'll take a look at your PR and see if there's any feedback I can provide. @nrc, thanks for the tip about #2531, I just replied in that issue! |
check
write modecheck
write mode follow-up
And don't print end of line characters by default in diffs cc #2536
Described in #1977 (comment) This would be used mainly by CI and would emit exit code 0 if no formatting was necessary and 1 if formatting is necessary. The output to stdout would be the same as
diff
mode.Mentoring instructions:
Implementation
check
to the rustfmt bin optionscheck
likediff
mode, but with different exit codes (will require refactoring or exit code handling, I think)check
modeFollow ups
cargo fmt
exit codes withrustfmt
ones (this might be trivial once this issue is fixed)The text was updated successfully, but these errors were encountered: