mirror of
https://github.com/sharkdp/hyperfine.git
synced 2026-10-12 02:22:35 +00:00
docs: simplify branch comparison example
This commit is contained in:
@@ -95,14 +95,9 @@ the measured command:
|
||||
hyperfine \
|
||||
--parameter-list branch main,performance-improvements \
|
||||
--setup 'git switch {branch}' \
|
||||
'rails runner true'
|
||||
'python main.py'
|
||||
```
|
||||
|
||||
Make sure your working tree is clean before switching branches. Because this `--setup` command
|
||||
changes the checkout, the repository will remain on the last branch from `--parameter-list`
|
||||
after the benchmark finishes. If you want to benchmark uncommitted changes, consider using
|
||||
`git worktree` and benchmarking the same command in each worktree instead.
|
||||
|
||||
### Intermediate shell
|
||||
|
||||
By default, commands are executed using `sh` on Unix (resolved through `PATH`) or `cmd.exe` on Windows.
|
||||
|
||||
Reference in New Issue
Block a user