From cc7abc7563ac6eb503023b2c4383cfb526a03962 Mon Sep 17 00:00:00 2001 From: Mark Rousskov Date: Sun, 2 Aug 2020 10:54:13 -0400 Subject: [PATCH] Avoid dumping rustc invocations to stdout These are quite long, usually, and in most cases not interesting. On smaller terminals they can take up more than a full page of output, hiding the error diagnostics emitted. --- src/bootstrap/bin/rustc.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/bootstrap/bin/rustc.rs b/src/bootstrap/bin/rustc.rs index d6649d0521ca3..4dd71ebade1a4 100644 --- a/src/bootstrap/bin/rustc.rs +++ b/src/bootstrap/bin/rustc.rs @@ -171,7 +171,9 @@ fn main() { // note: everything below here is unreachable. do not put code that // should run on success, after this block. } - println!("\nDid not run successfully: {}\n{:?}\n-------------", status, cmd); + if verbose > 0 { + println!("\nDid not run successfully: {}\n{:?}\n-------------", status, cmd); + } if let Some(mut on_fail) = on_fail { on_fail.status().expect("Could not run the on_fail command");