Commit Graph

9 Commits

Author SHA1 Message Date
Ævar Arnfjörð Bjarmason
017d55a4a1 Add --setup (-s) option, like --prepare but runs once per batch
Add a --setup option for the use-case of wanting to do one-off setup
before a set of benchmarks, not the once-per-test setup that --prepare
does. This is useful for the cases noted in the updated documentation.

Per the feedback on https://github.com/sharkdp/hyperfine/pull/448 this
new "--setup" option will steal the "-s" short option from
"--style" (initially this was called "--build" and used the
non-conflicting "-b").

Potential future work:

I'd prefer if this and --cleanup took N number of commands, so you
could do e.g.:

    hyperfine -L rev master,next \
        -b 'git worktree add /tmp/test-{r}'  \
        -b 'make -C /tmp/test-{r} all'  \
	'make -C /tmp/test-{r} test' \
	-c 'git worktree remove /tmp/test-{r}'

I.e. a shortcut around not providing these with &&, which makes things
a bit more readable.

But the --cleanup option doesn't do that, so let's just go with what
it's doing for consistency, so for this you'll now need to do:

    hyperfine -L rev master,next \
        -b 'git worktree add /tmp/test-{r} &&
	    make -C /tmp/test-{r} all'  \
	'make -C /tmp/test-{r} test' \
	-c 'git worktree remove /tmp/test-{r}'
2021-11-16 21:36:35 +01:00
Stéphane Campinas
71a47c0566 use --command-name for the long option 2020-10-15 22:42:44 +02:00
Stéphane Campinas
746e5fe687 update man page with the name CLI option 2020-10-15 22:42:44 +02:00
Cade Ekblad-Frank
9b7ded7feb Remove comment since it causes a syntax error when run with older versions of man (i.e. 1.6g on MacOS) 2020-07-30 21:21:58 +02:00
Alain Martin
4db0115e8e Fix case of "GitHub" 2020-05-22 22:43:49 +02:00
Alain Martin
d5e20cc760 Fix case of "AsciiDoc"
This matches how it is written on the README.
2020-05-22 22:43:49 +02:00
Alain Martin
b97ecf01c2 Fix typo seperated -> separated 2020-05-22 22:43:49 +02:00
Cade Ekblad-Frank
e595be7d5a Address code review:
* Update basic benchmark example
  * Clarify warm up example
  * Add manpage to generated tarballs and debs (bit of YOLO here, need to spin an instance to verify build output but the additions as modeled from fd are innocuous)
2020-01-18 20:52:56 +01:00
Cade Ekblad-Frank
5911e1ca4b Add basic manpage 2020-01-18 20:52:56 +01:00