#cli Clear
Tags #php #kotlin #bash #go #sql #rust #typescript #html #java #python #files #utils #strings #http #concurrency #async #json #arrays #security #types #crypto #database #dates #format
Bash Parse --flag=value Arguments
A getopts-free arg parser handling long flags, equals-separated values, and bundled short flags. Customize as needed.
Bash Self-Documenting Help Text
A pattern where comments in your script double as inline help. Grep your own file for a sentinel string and print it as the --help output.
Python argparse with Subcommands
Standard-library CLI framework. Subcommands (like `git COMMAND`) require a sub-parser per command, each with its own arguments and handler.
Rust clap — Derive-Style CLI Parser
`clap` with the derive macro turns a Rust struct into a fully-featured CLI: `--help`, `--version`, validation, subcommands. The most popular CLI framework in the Rust ecosystem.
Go flag — Stdlib CLI Parser
The `flag` package is the minimal-dep CLI parser shipped with Go. Sufficient for many tools; reach for `spf13/cobra` or `urfave/cli` for subcommands and richer UX.