Cli for agent

From ariadoss/superskills · View interactive version

Cli for agent is an AI agent skill from the GitHub repository ariadoss/superskills. Design or review CLIs so coding agents can run them reliably: non-interactive flags first, layered --help with real copy-pasteable examples, stdin/pipeline support, fail-fast errors that include a correct invocation, idempotency, --dry-run/--yes for destructive actions, and machine-useful success ou

How to use this skill

Skill file

/cli-for-agent

Human-oriented CLIs block agents: interactive prompts, huge upfront docs, and

help text without copy-pasteable examples. Prefer patterns that work headlessly

and compose in pipelines.

Non-interactive first

arrow keys, menus, or timed prompts.

way around.

Bad: mycli deploy → ? Which environment? (use arrow keys)

Good: mycli deploy --env staging

Discoverability without dumping context

--help`. Do not print the entire manual on every run.

context.

`--help` that works

than prose for pattern-matching.

Options:
  --env     Target environment (staging, production)
  --tag     Image tag (default: latest)
  --force   Skip confirmation

Examples:
  mycli deploy --env staging
  mycli deploy --env production --tag v1.2.3
  mycli deploy --env staging --force

stdin, flags, and pipelines

import --stdin`).

for missing values.

tag-only)`.

Fail fast with actionable errors

correct example invocation, not a hang.

Error: No image tag specified.
  mycli deploy --env staging --tag <image-tag>
  Available tags: mycli build list --output tags

Idempotency

(no-op or explicit "already done"), not duplicate side effects.

Destructive actions

committing.

for humans.

Predictable structure

service list exists, mycli deploy list and mycli config list` should

follow the same shape.

Success output

fine; avoid relying on decorative output alone.

deployed v1.2.3 to staging
url: https://staging.myapp.com
deploy_id: dep_abc123
duration: 34s

When reviewing an existing CLI

stdin/pipeline story, error messages with invocations, idempotency,

dry-run, confirmation bypass flags, consistent command structure,

structured success output.


Adapted from cursor/plugins

cli-for-agent/skills/cli-for-agents/SKILL.md (MIT, © Cursor). Vendored per

the superskills imported-skills rule; changes here do not track upstream.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.