cli-development

Create Node.js CLI structures with argv-based routing and argument parsing.

Updated Feb 10, 2026
One-click install
npx skills add https://github.com/aaronmaturen/rumpleskill --skill cli-development-aaronmaturen
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: cli-development
Source: https://github.com/aaronmaturen/rumpleskill/tree/main/.claude/skills/cli-development
Command: npx skills add https://github.com/aaronmaturen/rumpleskill --skill cli-development-aaronmaturen

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Node.js CLI development often involves repetitive patterns for routing commands, parsing arguments, and managing stdio and error handling. This skill provides a reusable blueprint to implement clean, minimal CLIs without external frameworks.

Core Features & Use Cases

  • Command Routing: simple argument-based routing via process.argv
  • Flag Handling: boolean and value flags with predictable behavior
  • Stream Output: real-time feedback through inherited stdio
  • Error Reporting: clear non-zero exit codes and stderr messages
  • Use Case: rapidly scaffold a new CLI tool for internal tooling or small projects

Quick Start

Create a new command by extending the routing in src/index.ts and then run rumpleskill to generate the associated docs.

Frequently Asked Questions about cli-development

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

FAQPage Schema
How do I build a Node.js CLI with command routing without external frameworks?

You can build a Node.js CLI by implementing a simple argv-based routing approach via process.argv in your entry point. This provides command routing and flag parsing without requiring external CLI frameworks.

What is the best way to handle stdio and error reporting in a Node.js command line tool?

The best way to handle stdio and error reporting is by using inherited stdio for real-time feedback and writing clear error messages to stderr with proper non-zero exit codes for failures.

How do I parse boolean and value flags for a Node.js CLI?

You parse boolean and value flags by extending the argument routing logic in your entry point. This approach ensures predictable flag handling behavior directly within your Node.js application.

Is a manual argv routing approach suitable for large Node.js CLI applications?

A manual argv routing approach is suited for small to medium CLIs and internal tooling. It provides a clean, minimal structure for rapidly scaffolding new commands without external dependencies.

Why does my Node.js CLI exit with a zero code on failure?

Your Node.js CLI likely exits with a zero code because proper non-zero exit codes are not implemented. You must explicitly set non-zero exit codes when outputting error messages to stderr.