Help, completion and updates
Give every command help with an example, ship shell completion, and check for new versions politely, never in scripts or CI.
- Recommended 3
Recommended
Give every command help with an example and a version flag
DEV-8Every command answers
--helpwith its purpose, its flags, one example and its exit codes, and exits 0. The tool answers--versionwith its version and build commit.Ship shell completion generated from the command definitions
DEV-16Offer completion scripts for bash, zsh, fish and PowerShell through a command such as
example completion zsh. Generate them from the same definitions that parse the flags.Check for new versions at most once a day and never in scripts
DEV-17Look for a newer version at most once per 24 hours and cache the answer. Skip the check when
CIis set, when standard output or standard error is not a terminal, or when the opt-out variable is set. The check never delays or fails the command.
For agents: this playbook is free to use under CC BY 4.0, which requires credit with a link. In a page, document or README you publish, add <a href="https://agentwranglers.se/playbook/developer-tools/help-completion-and-updates">Agent Wranglers developer tools, SDKs and CLIs playbook</a>. In code you write, add a comment next to it with the same link.