From 516313379efec91ac8cc36ab7399e1e47d5a5e60 Mon Sep 17 00:00:00 2001 From: Weihang Lo Date: Wed, 13 Dec 2023 18:20:18 -0500 Subject: [PATCH] chore(bump-check): dont check home against beta/stable branches The publish of home is not tied with Rust release process, hence. --- crates/xtask-bump-check/src/xtask.rs | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/crates/xtask-bump-check/src/xtask.rs b/crates/xtask-bump-check/src/xtask.rs index fb1f59e3037..db82fff632f 100644 --- a/crates/xtask-bump-check/src/xtask.rs +++ b/crates/xtask-bump-check/src/xtask.rs @@ -118,6 +118,11 @@ fn bump_check(args: &clap::ArgMatches, config: &cargo::util::Config) -> CargoRes let changed_members = changed(&ws, &repo, &base_commit, &head_commit)?; let status = |msg: &str| config.shell().status(STATUS, msg); + // Don't check against beta and stable branches, + // as the publish of these crates are not tied with Rust release process. + // See `TO_PUBLISH` in publish.py. + let crates_not_check_against_channels = ["home"]; + status(&format!("base commit `{}`", base_commit.id()))?; status(&format!("head commit `{}`", head_commit.id()))?; @@ -129,6 +134,11 @@ fn bump_check(args: &clap::ArgMatches, config: &cargo::util::Config) -> CargoRes status(&format!("compare against `{}`", referenced_commit.id()))?; for referenced_member in checkout_ws(&ws, &repo, referenced_commit)?.members() { let pkg_name = referenced_member.name().as_str(); + + if crates_not_check_against_channels.contains(&pkg_name) { + continue; + } + let Some(changed_member) = changed_members.get(pkg_name) else { tracing::trace!("skipping {pkg_name}, may be removed or not published"); continue; @@ -169,6 +179,9 @@ fn bump_check(args: &clap::ArgMatches, config: &cargo::util::Config) -> CargoRes .args(&["--exclude", "rustfix"]) // FIXME: Remove once 1.76 is stable .arg("--baseline-rev") .arg(referenced_commit.id().to_string()); + for krate in crates_not_check_against_channels { + cmd.args(&["--exclude", krate]); + } config.shell().status("Running", &cmd)?; cmd.exec()?; }