Rollup merge of #137220 - ferrocene:pa-channel-ci, r=Kobzol

Support `rust.channel = "auto-detect"`

As [discussed in Zulip](https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/vibe.20check.20for.20a.20few.20config.20changes), this PR adds the new `"auto-detect"` value for `rust.channel`, to load the channel name from `src/ci/channel`.

Note that in a previous iteration of this PR the value was "ci" instead of "auto-detect".
This commit is contained in:
许杰友 Jieyou Xu (Joe) 2025-02-28 21:41:59 +08:00 committed by GitHub
commit dedf61a29d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 15 additions and 5 deletions

View file

@ -1777,7 +1777,11 @@ impl Config {
let is_user_configured_rust_channel =
if let Some(channel) = toml.rust.as_ref().and_then(|r| r.channel.clone()) {
config.channel = channel;
if channel == "auto-detect" {
config.channel = ci_channel.into();
} else {
config.channel = channel;
}
true
} else {
false

View file

@ -360,4 +360,9 @@ pub const CONFIG_CHANGE_HISTORY: &[ChangeInfo] = &[
severity: ChangeSeverity::Info,
summary: "Added `build.test-stage = 2` to 'tools' profile defaults",
},
ChangeInfo {
change_id: 137220,
severity: ChangeSeverity::Info,
summary: "`rust.channel` now supports \"auto-detect\" to load the channel from `src/ci/channel`",
},
];