1
Fork 0

Rollup merge of #112886 - clubby789:revert-user-dist, r=albertlarsan68

Revert 'Rename profile=user to profile=dist'

This reverts commit a45fc94652 (#112166)
Reverted as it didn't meet the requirements (https://github.com/rust-lang/rust/pull/112166#issuecomment-1574627502) and is causing issues (closes #112846)

cc ``@AnakinSkywalkeer``
This commit is contained in:
Guillaume Gomez 2023-06-21 15:45:19 +02:00 committed by GitHub
commit a687a96df0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -20,7 +20,7 @@ pub enum Profile {
Codegen, Codegen,
Library, Library,
Tools, Tools,
Dist, User,
None, None,
} }
@ -43,7 +43,7 @@ impl Profile {
pub fn all() -> impl Iterator<Item = Self> { pub fn all() -> impl Iterator<Item = Self> {
use Profile::*; use Profile::*;
// N.B. these are ordered by how they are displayed, not alphabetically // N.B. these are ordered by how they are displayed, not alphabetically
[Library, Compiler, Codegen, Tools, Dist, None].iter().copied() [Library, Compiler, Codegen, Tools, User, None].iter().copied()
} }
pub fn purpose(&self) -> String { pub fn purpose(&self) -> String {
@ -53,7 +53,7 @@ impl Profile {
Compiler => "Contribute to the compiler itself", Compiler => "Contribute to the compiler itself",
Codegen => "Contribute to the compiler, and also modify LLVM or codegen", Codegen => "Contribute to the compiler, and also modify LLVM or codegen",
Tools => "Contribute to tools which depend on the compiler, but do not modify it directly (e.g. rustdoc, clippy, miri)", Tools => "Contribute to tools which depend on the compiler, but do not modify it directly (e.g. rustdoc, clippy, miri)",
Dist => "Install Rust from source", User => "Install Rust from source",
None => "Do not modify `config.toml`" None => "Do not modify `config.toml`"
} }
.to_string() .to_string()
@ -73,7 +73,7 @@ impl Profile {
Profile::Codegen => "codegen", Profile::Codegen => "codegen",
Profile::Library => "library", Profile::Library => "library",
Profile::Tools => "tools", Profile::Tools => "tools",
Profile::Dist => "dist", Profile::User => "user",
Profile::None => "none", Profile::None => "none",
} }
} }
@ -87,7 +87,7 @@ impl FromStr for Profile {
"lib" | "library" => Ok(Profile::Library), "lib" | "library" => Ok(Profile::Library),
"compiler" => Ok(Profile::Compiler), "compiler" => Ok(Profile::Compiler),
"llvm" | "codegen" => Ok(Profile::Codegen), "llvm" | "codegen" => Ok(Profile::Codegen),
"maintainer" | "dist" => Ok(Profile::Dist), "maintainer" | "user" => Ok(Profile::User),
"tools" | "tool" | "rustdoc" | "clippy" | "miri" | "rustfmt" | "rls" => { "tools" | "tool" | "rustdoc" | "clippy" | "miri" | "rustfmt" | "rls" => {
Ok(Profile::Tools) Ok(Profile::Tools)
} }
@ -160,7 +160,7 @@ pub fn setup(config: &Config, profile: Profile) {
"test src/tools/rustfmt", "test src/tools/rustfmt",
], ],
Profile::Library => &["check", "build", "test library/std", "doc"], Profile::Library => &["check", "build", "test library/std", "doc"],
Profile::Dist => &["dist", "build"], Profile::User => &["dist", "build"],
}; };
println!(); println!();
@ -170,7 +170,7 @@ pub fn setup(config: &Config, profile: Profile) {
println!("- `x.py {}`", cmd); println!("- `x.py {}`", cmd);
} }
if profile != Profile::Dist { if profile != Profile::User {
println!( println!(
"For more suggestions, see https://rustc-dev-guide.rust-lang.org/building/suggested.html" "For more suggestions, see https://rustc-dev-guide.rust-lang.org/building/suggested.html"
); );