Skip to content

Create TypeScript CLIs

Build production-style TypeScript command-line tools with help text, JSON output and exit codes

Stars
19,682
Licence
MIT
Files
7 files

What it does

Once installed, the agent can turn a request like 'build a CLI for this API' into a complete TypeScript command-line tool. It picks one of three complexity tiers (simple hand-written argument parsing by default, Commander.js for larger tools with subcommands, or oclif as reference only), then generates source code, a README and quickstart, package.json and strict TypeScript config, JSON output and documented exit codes. A bundled checker script can then verify the result.

Great for

  • Developers who want a quick, consistently structured CLI wrapping an API or automating a task
  • Personal productivity users building tools inside a LifeOS/Claude setup
  • Teams that want a shared CLI contract (JSON to stdout, exit 0/1, documented help)

Skip it if

  • Projects that do not use Bun or TypeScript, since the skill mandates both and forbids npm, npx and Python helpers
  • Anyone expecting a finished, audited product: generated CLIs still need human review against the requested commands, output and docs, as the skill itself notes

Try asking

  • “Create a CLI for the GitHub API that can list my repositories and open issues”
  • “Build a command-line tool that converts CSV files to JSON”
  • “Add a 'sync' command to my existing notes CLI”
  • “Upgrade my CLI to Commander.js because it now has many subcommands”
Step-by-step guide: how to use Create TypeScript CLIsInstall, first run, examples, tips and FAQs

Install in 3 steps

  1. 1

    Download the skill

    The ZIP contains the 7 original files, the MIT licence and an attribution note.

    CreateCLI.zip
  2. 2

    Add it to your agent

    Claude Code (all projects)

    mkdir -p ~/.claude/skills && unzip CreateCLI.zip -d ~/.claude/skills/

    Claude Code / Agent SDK (this project only)

    mkdir -p .claude/skills && unzip CreateCLI.zip -d .claude/skills/

    Claude apps (web/desktop): Settings → Capabilities → Skills → Upload skill, and choose the ZIP.

  3. 3

    Ask for the task

    No special command needed — the agent reads the skill's description and loads it when your request matches. Try one of the prompts above.

Get better results

  • State the exact commands, arguments and output format you need up front so the generated CLI can be checked against them.
  • Run the bundled CheckCli.ts script (bun Tools/CheckCli.ts <cli-dir>) after generation to confirm tsc, help, version, unknown-command and JSON checks pass.
  • Review generated code before running it, and keep API keys out of source files; store them in ~/.claude/.env as the skill directs.

What's inside

  • FrameworkComparison.md
  • Intents/AddCommand.md
  • Intents/CreateCli.md
  • Intents/UpgradeTier.md
  • Setup.md
  • SKILL.md
  • Tools/CheckCli.ts

Redistributed unmodified from danielmiessler/LifeOS under the MIT licence. The assessment was drafted with AI from the skill's files on 2026-10-29. Skills can instruct your agent to run code — read SKILL.md and any scripts before installing.