CLI Help Text Patterns

Write CLI help text following POSIX and GNU conventions.

Updated Feb 25, 2026
One-click install
npx skills add https://github.com/HermeticOrmus/LibreCopy-Claude-Code --skill cli-help-text-patterns
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: CLI Help Text Patterns
Source: https://github.com/HermeticOrmus/LibreCopy-Claude-Code/tree/main/plugins/cli-help-text/skills/cli-help-patterns
Command: npx skills add https://github.com/HermeticOrmus/LibreCopy-Claude-Code --skill cli-help-text-patterns

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides clear, consistent, and user-friendly help text for command-line interfaces, improving usability and reducing user error.

Core Features & Use Cases

  • Standardized Syntax: Explains POSIX usage line conventions (optional, required, repeatable, mutually exclusive).
  • Option Naming: Details GNU long option rules and common POSIX short option meanings.
  • Formatting Best Practices: Guides on aligning descriptions, documenting defaults, and marking required options.
  • Examples & Environment Variables: Emphasizes the importance of clear examples and documents environment variable usage.
  • Exit Codes: Defines standard exit codes for predictable behavior.
  • Use Case: A developer writing a new CLI tool can use this Skill to ensure their help messages are intuitive and follow established conventions, making the tool easier for others to adopt.

Quick Start

Consult the CLI Help Text Patterns skill for guidance on documenting command-line options and usage.

Frequently Asked Questions about CLI Help Text Patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What are the standard POSIX and GNU conventions for writing CLI help text?

CLI help text conventions standardize usage lines, option naming, and argument formatting following POSIX and GNU rules. This ensures command-line interfaces remain predictable, reducing user error and improving overall usability.

How do I format optional, required, and mutually exclusive arguments in a command-line usage line?

Format command-line usage lines using POSIX conventions to denote optional, required, repeatable, and mutually exclusive arguments. This syntax standardization clarifies complex input combinations for developers and end-users.

What is the best way to document environment variables and exit codes in command-line tools?

Document environment variables and define standard exit codes within your CLI help text to ensure predictable behavior. Clearly explaining these elements helps users automate scripts and handle execution errors effectively.

How should I align descriptions and document defaults for CLI options?

Align option descriptions and explicitly state default values in CLI help text formatting. Marking required options clearly follows best practices, guiding users toward valid command execution without unnecessary trial and error.

Why does standardizing command-line interface documentation improve developer productivity?

Standardizing command-line interface documentation improves developer productivity by providing intuitive, consistent help messages. Following established GNU and POSIX conventions reduces the learning curve for new tools and minimizes user input errors.

Can I use these CLI help text guidelines for any command-line tool?

Yes, you can apply these CLI help text guidelines to any command-line tool. They provide general best practices for usage lines, option naming, and examples without requiring specific frameworks or dependencies.