-
Notifications
You must be signed in to change notification settings - Fork 888
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
Is there a simple way to install rusftmt 2.0 rc without building from source? #4582
Comments
hello @Kungitoo 👋 thanks for the question and welcome! 🦀
No there's not. The primary distribution channel for rustfmt is via rustup and the associated rust releases. https://github.com/rust-lang/rustfmt#installing-from-source rustfmt is also available on crates.io (though it's several versions behind the latest version available via rustup), but there's really not must of a difference in the experience between installing from crates.io vs. installing from source: both involve building and both utilize the
Think the installation bit was covered above, and Also regarding your question from #4437 (comment)
We were actually ready to ship the 2.0 release back in the spring, but as we were starting that process there were various concerns and objections about having a breaking/2.0 release for an official tool that ships with the main Rust distribution (which itself is on a 1.x version). There definitely won't be a 2.0 release in 2020, and long term I'm honestly not sure what the plan is going to be. It's entirely plausible we may never be able to do so, or at least not until there's a hypothetical 2.0 release of Rust, due to the combination of how seriously Rust takes stability and rustfmt's own stability guarantee. Here was the original milestone we had tracking the 2.0 release: |
Could you release 2.0 version to be available under some flag? I know this would never pass, but could you bundle 2.0 code with the 1.x package and then when some flag is specified we use the 2.0 code which is completely separate so it doesn't interfere with the stable 1.x version? |
If you only need
It's mine
|
No. I appreciate your interest in the potential 2.0 version, but it's not released right now by design for the reasons I shared above and that's not going to change any time soon. If you want to use the unreleased version of rustfmt from the source control repository, then you're going to have to work with the source control repository in your local and/or CI environments. Going to go ahead and close this given that the question has been answered, thanks again for reaching out! |
@francis-du - I'd advise against mixing and matching different major versions of https://github.com/rust-lang/rustfmt#running-cargo-fmt Please be aware that there's substantial differences in the 2.x version of rustfmt that the 1.x version of cargo fmt doesn't necessarily work with, notably, rustfmt 2.x is not recursive by default so if you run |
@calebcartwright Thanks for reminding : ) |
Sure thing, thanks for sharing your findings! |
If rustfmt 2 is not going to be released, what does that mean for the added configuration options which were stabilised only in 2.0? Are those stabilisations going to get backported? Is there a blog or discussion thread somewhere with more insight into what is going to be happening instead? I’d been holding off for an official v2 release to formally adopt rustfmt in a project I have been working on, so it would be nice to get a sense of what the plan is. A quick search did not surface anything about this on rust-internals or rust-users forums. Thanks! |
Hey!
I'm new to the rust ecosystem and would like to try out 2.0. Is there a simple way to install and then uninstall the 2.0 versions?
From what I see the nightly versions on cargo are 1.4.x as well
The text was updated successfully, but these errors were encountered: