diff --git a/cargo-dist/src/lib.rs b/cargo-dist/src/lib.rs index c3fc41ab3..5d5efb34f 100644 --- a/cargo-dist/src/lib.rs +++ b/cargo-dist/src/lib.rs @@ -61,14 +61,17 @@ mod tests; pub fn do_env_test(cfg: &Config) -> DistResult<()> { let (dist, _manifest) = tasks::gather_work(cfg)?; - let global_builds = cfg.artifact_mode == ArtifactMode::Global; + let local_builds = matches!( + cfg.artifact_mode, + ArtifactMode::Local | ArtifactMode::All | ArtifactMode::Host + ); let builds = dist.config.builds; // cargo-auditable is used only in local builds - let need_cargo_auditable = builds.cargo.cargo_auditable && !global_builds; + let need_cargo_auditable = builds.cargo.cargo_auditable && local_builds; // cyclonedx is used only in global builds - let need_cargo_cyclonedx = builds.cargo.cargo_cyclonedx && global_builds; + let need_cargo_cyclonedx = builds.cargo.cargo_cyclonedx && !local_builds; // omnibor is used in both local and global builds let need_omnibor = builds.omnibor; let mut need_xwin = false;