cli-developer

Design and implement CLI tools with argument parsing for Node.js, Python, and Go.

19|3|Updated Mar 11, 2026
One-click install
npx skills add https://github.com/dirien/yet-another-agent-harness --skill cli-developer-dirien
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cli-developer
Source: https://github.com/dirien/yet-another-agent-harness/tree/main/.claude/skills/cli-developer
Command: npx skills add https://github.com/dirien/yet-another-agent-harness --skill cli-developer-dirien

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Command-line interfaces are easy to get wrong: inconsistent flags, poor help text, fragile argument parsing, missing completions, and platform-specific behavior cause poor UX and maintenance burden. This skill provides patterns, framework-specific examples, and operational constraints to help teams design, implement, and test robust, cross-platform CLIs.

Core Features & Use Cases

  • Command design & UX: plan subcommands, consistent flag names, help text, and command hierarchies to make tools discoverable and predictable.
  • Framework-specific guidance: implementation recipes and best practices for Node.js (commander, yargs), Python (typer, click, argparse), and Go (cobra, viper, bubbletea).
  • Polish & reliability: generate shell completions, detect TTY for colored output, handle SIGINT gracefully, add progress indicators and interactive prompts, and require cross-platform testing.
  • Testing & distribution: guidance for snapshot and E2E tests, packaging (npm, pip, homebrew), and performance targets (startup <50ms) for production-grade CLIs.
  • Use Case: implement a deploy command with robust flag validation, non-interactive CI fallbacks, and generated bash and zsh completions.

Quick Start

Create a CLI with a greet subcommand that accepts a name and a --loud flag, prints a greeting, supports --help and --version, and emits shell completion scripts for bash and zsh.

Frequently Asked Questions about cli-developer

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

FAQPage Schema
How do I build a CLI with robust argument parsing and subcommands?

To build a CLI with robust argument parsing, design a command hierarchy with subcommands, consistent flag names, and clear help text. Apply framework-specific recipes for Node.js, Python, or Go to ensure predictable and discoverable tools.

Does this CLI development approach support Node.js, Python, and Go?

Yes, this CLI development approach supports Node.js, Python, and Go. It provides implementation recipes and best practices for frameworks like commander, yargs, typer, click, argparse, cobra, viper, and bubbletea.

What's the best way to add shell completions and interactive prompts to a command-line tool?

The best way to add shell completions and interactive prompts is to generate bash and zsh completion scripts and detect TTY for colored output. Handle SIGINT gracefully and add progress indicators to improve command-line tool UX.

How do I test and package a CLI for cross-platform reliability?

Test and package a CLI for cross-platform reliability by running snapshot and E2E tests, and distributing via npm, pip, or homebrew. Require cross-platform testing and enforce startup performance targets under 50ms.

How do I handle non-interactive CI fallbacks and flag validation in a CLI?

Handle non-interactive CI fallbacks and flag validation by implementing layered configuration sources and robust argument checks. Ensure your CLI validates flags correctly and provides non-interactive fallbacks for automated environments.

Why does my command-line tool have inconsistent flags and fragile argument parsing?

Command-line tools have inconsistent flags and fragile argument parsing due to poor design and lack of framework patterns. Apply structured subcommand planning, consistent flag naming, and robust parsing frameworks to resolve these issues.