LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

cmdperf

Interactive command-line benchmarking tool

TLDR

Benchmark a single command with default 10 runs
$ cmdperf "sleep 0.1"
copy
Compare two commands side-by-side
$ cmdperf "grep 'ERROR' log.txt" "rg 'ERROR' log.txt"
copy
Run 100 iterations of a command
$ cmdperf -n 100 "ls -la"
copy
Simulate 10 concurrent requests
$ cmdperf -c 10 "curl -s https://example.com > /dev/null"
copy
Run for a fixed duration of 30 seconds
$ cmdperf -d 30s "redis-cli PING"
copy
Export results to a markdown file
$ cmdperf --markdown [results.md] "sleep 0.1" "sleep 0.2"
copy

SYNOPSIS

cmdperf [options] command [command...]

DESCRIPTION

cmdperf runs one or more shell commands repeatedly and gathers timing statistics, displaying them in a live terminal UI with a progress bar, ETA, and key metrics including mean execution time, standard deviation, and min/max ranges. It supports single command benchmarking, multi-command comparison, concurrent execution to simulate load, duration-based runs, and rate limiting for HTTP endpoint testing.

PARAMETERS

-n, --runs=N

Number of iterations to run (default: 10).
-c, --concurrency=N
Number of parallel executions (default: 1).
-d, --duration=DURATION
Run for a fixed duration instead of a fixed number of runs.
-r, --rate=RATE
Target request rate in requests per second.
-t, --timeout=DURATION
Per-command timeout (default: 1m).
-s, --shell=SHELL
Shell to use for command execution (default: /bin/sh).
--shell-opt=OPT
Shell option, repeatable (default: -c).
-N, --no-shell
Execute command directly without wrapping in a shell.
--csv=FILE
Export results to CSV file.
--markdown=FILE
Export results to Markdown file.
--fail-on-error
Exit with non-zero status if any command returns non-zero exit code.
--color-scheme=SCHEME
Set color scheme (auto, catppuccin, tokyonight, nord, monokai, solarized, solarized-light, gruvbox, monochrome).
--list-color-schemes
Display available color schemes.
--version
Display version information.

CAVEATS

Designed for quick interactive benchmarking, not a replacement for rigorous statistical profiling tools. Default shell wrapping adds overhead; use -N/--no-shell for tighter measurements when shell features are not needed.

HISTORY

cmdperf was created by miklosn and is written in Go under the MIT license. The latest release is v0.1.4 (January 2026). It fills a niche as a lightweight, interactive alternative to tools like hyperfine, with a focus on live TUI experience and concurrent execution simulation.

SEE ALSO

hyperfine(1), time(1), perf(1)

Braincup
Open source brain training for math, memory and focus
Braincup mini-games
41 mini-games · Apache-2.0
No ads · No tracking
Play in browser
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid
276 stars
From the maker of Linux Command Library
Copied to clipboard
Braincup
Open source brain training for math, memory and focus. 41 mini-games, from mental arithmetic to Sudoku, N-Back and Solo Chess.
Apache-2.0 licensed · No ads · No tracking · No account
From the maker of Linux Command Library
Download Braincup on the App StoreGet Braincup on Google PlayGet Braincup on F-Droid