Merge pull request #900 from ded-furby/docs/hyperfine-iteration-readme

docs: mention HYPERFINE_ITERATION in README
This commit is contained in:
David Peter authored and GitHub committed 2026-10-05 12:07:23 +02:00
commit a2d7094282
1 file changed
+6
+6
View File
@@ -98,6 +98,12 @@ hyperfine \
'python main.py'
```
If you need a unique value for each individual run of a benchmark command, hyperfine also exposes
the zero-based `$HYPERFINE_ITERATION` environment variable inside the benchmarked command itself:
```sh
hyperfine 'my-command > output-${HYPERFINE_ITERATION}.log'
```
### Intermediate shell
By default, commands are executed using `sh` on Unix (resolved through `PATH`) or `cmd.exe` on Windows.