diff options
| author | Mazdak Farrokhzad <twingoow@gmail.com> | 2019-08-03 00:09:07 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-08-03 00:09:07 +0200 |
| commit | 726f39a2585ede14c4e75ac440293fb556d49af5 (patch) | |
| tree | c4519bcb33d61336ba151cbddc47b83d221197c6 /src/bootstrap | |
| parent | edc846f29eac8a45555f19a9fd951ed414398776 (diff) | |
| parent | 30f61dec30c01c260587760770da83b29d9cce6a (diff) | |
| download | rust-726f39a2585ede14c4e75ac440293fb556d49af5.tar.gz rust-726f39a2585ede14c4e75ac440293fb556d49af5.zip | |
Rollup merge of #63196 - RalfJung:build_helper, r=alexcrichton
build_helper: try less confusing method names build_helper's `*_silent` methods were likely called that way because they do not print the command being run to stdout. [In the original file this all makes sense](https://github.com/rust-lang/rust/commit/046e6874c47ec55e23b7a566bca51d2920562485#diff-5c3d6537a43ecae03014e118a7fe3321). But later it also gained `*_suppressed` methods and the difference between `silent` and `suppressed` is far from clear. So rename `run` (which prints the command being run) to `run_verbose`. Then we can call the methods that just run a command and show its output but nothing extra `run` and `try_run`. `run_verbose` (formerly `run`) is unused from what I can tell. Should I remove it? r? @alexcrichton Cc @Mark-Simulacrum Also see https://github.com/rust-lang/rust/pull/63089#discussion_r308018890.
Diffstat (limited to 'src/bootstrap')
| -rw-r--r-- | src/bootstrap/lib.rs | 6 | ||||
| -rw-r--r-- | src/bootstrap/test.rs | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/bootstrap/lib.rs b/src/bootstrap/lib.rs index c2e64ef51a7..c8ea3157dc9 100644 --- a/src/bootstrap/lib.rs +++ b/src/bootstrap/lib.rs @@ -125,7 +125,7 @@ use std::os::unix::fs::symlink as symlink_file; use std::os::windows::fs::symlink_file; use build_helper::{ - mtime, output, run_silent, run_suppressed, t, try_run_silent, try_run_suppressed, + mtime, output, run, run_suppressed, t, try_run, try_run_suppressed, }; use filetime::FileTime; @@ -682,7 +682,7 @@ impl Build { fn run(&self, cmd: &mut Command) { if self.config.dry_run { return; } self.verbose(&format!("running: {:?}", cmd)); - run_silent(cmd) + run(cmd) } /// Runs a command, printing out nice contextual information if it fails. @@ -698,7 +698,7 @@ impl Build { fn try_run(&self, cmd: &mut Command) -> bool { if self.config.dry_run { return true; } self.verbose(&format!("running: {:?}", cmd)); - try_run_silent(cmd) + try_run(cmd) } /// Runs a command, printing out nice contextual information if it fails. diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs index fec7f73f3b7..1f81efd16a7 100644 --- a/src/bootstrap/test.rs +++ b/src/bootstrap/test.rs @@ -1527,7 +1527,7 @@ impl Step for RustcGuide { fn run(self, builder: &Builder<'_>) { let src = builder.src.join("src/doc/rustc-guide"); let mut rustbook_cmd = builder.tool_cmd(Tool::Rustbook); - try_run_quiet(builder, rustbook_cmd.arg("linkcheck").arg(&src)); + try_run(builder, rustbook_cmd.arg("linkcheck").arg(&src)); } } |
