Implement --output={null,pipe,<FILE>}

Fixes #377.
This commit is contained in:
Tavian Barnes authored and David Peter committed 2022-05-17 22:30:45 +02:00
1 parent f75f0a10fe
commit 277807cb5a
6 files changed
+129 -23

No files matched your search

+14
View File
@@ -259,6 +259,20 @@ fn build_command() -> Command<'static> {
when trying to benchmark output speed.",
),
)
.arg(
Arg::new("output")
.long("output")
.conflicts_with("show-output")
.takes_value(true)
.value_name("WHERE")
.help(
"Control where the output of the benchmark is redirected.\n\n \
null: Redirect output to /dev/null (the default).\n\n \
pipe: Feed the output through a pipe before discarding it.\n \
Useful if the benchmark special-cases /dev/null.\n\n \
<FILE>: Write the output to the given file.",
),
)
.arg(
Arg::new("command-name")
.long("command-name")