Skip to content

Commit 771b255

Browse files
Rollup merge of #117322 - onur-ozkan:fix-suppressed-outputs, r=Kobzol
change default output mode of `BootstrapCommand` `SuppressOnSuccess` on `BootstrapCommand` is a problematic default mode as it affects the logs during the bootstrapping (as shown in the screenshot below). The default behavior should be to print everything unless we explicitly modify the behavior within build steps. ![image](https://github.com/rust-lang/rust/assets/39852038/8dbaaeb2-0656-4ff9-8e48-1ac0734a913f) Fixes #117315 cc `@Kobzol`
2 parents 577f86d + 236f6ba commit 771b255

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

Diff for: src/bootstrap/src/lib.rs

+5-1
Original file line numberDiff line numberDiff line change
@@ -586,7 +586,11 @@ impl Build {
586586
.args(&["diff-index", "--quiet", "HEAD"])
587587
.current_dir(&absolute_path),
588588
)
589-
.allow_failure(),
589+
.allow_failure()
590+
.output_mode(match self.is_verbose() {
591+
true => OutputMode::PrintAll,
592+
false => OutputMode::PrintOutput,
593+
}),
590594
);
591595
if has_local_modifications {
592596
self.run(Command::new("git").args(&["stash", "push"]).current_dir(&absolute_path));

Diff for: src/bootstrap/src/utils/exec.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ impl<'a> From<&'a mut Command> for BootstrapCommand<'a> {
5454
Self {
5555
command,
5656
failure_behavior: BehaviorOnFailure::Exit,
57-
output_mode: OutputMode::SuppressOnSuccess,
57+
output_mode: OutputMode::PrintAll,
5858
}
5959
}
6060
}

0 commit comments

Comments
 (0)