-
Notifications
You must be signed in to change notification settings - Fork 925
--check output is editor-unfriendly. #4092
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
When you say editor-unfriendly, what's the context? Editor/IDE plugins that facilitate running rustfmt (on-demand, format-on-save) or something else? Would the |
I mean editors/IDE natively handling the text output, where In my case,
No, since something would have to process it. At that point I should bite the bullet and switch to VSCode Remote to the server, where I could just run RLS, have format on save, etc. What I'm hoping for is a tiny tweak to the |
👍 makes sense, thank you. I'd never noticed that type of navigation in editors before
Seems reasonable to me. It's indeed a really easy change if anyone is interested in making the update, otherwise I can probably get around to it eventually rustfmt/rustfmt-core/rustfmt-emitter/src/diff.rs Lines 34 to 38 in 9124dd8
|
FWIW, I found a way to run "runOnSave.commands": [
{
"match": "\\.rs$",
"command": "rustfmt --edition=2018 ${file}",
"runIn": "backend",
}
], EDIT: added |
While the ergonomic problem will likely go away whenever I get around to moving my setup to VSCode Remote, the current
--check
diff output is still pretty frustrating, and inconsistent with compiler output.The head of each diff chunk looks like this: (base dir omitted for clarity)
I suspect the
at line 48:
formatting is trying to be user-friendly or something, but if it was like this, it would be accessible without having to go to the line manually:For me it's Ctrl+click that I use, but I recall seeing an issue about some other editor (emacs perhaps?), where a more specific format might be needed, I just can't find that issue now.
The text was updated successfully, but these errors were encountered: