Skip to content

Swipe right for a newer agent, Automation Recipe Writer. Swipe left for an older agent, Error Message Poet.

Issue 22 · 26 Sep 2026 · Easy · Free

CLI Help Rewriter

AI prompt to write CLI usage examples from --help

The help text lists forty flags in alphabetical order, and the one command a person needs to copy is not among them.

Category
Dev Tools

Sample you can paste

$ ledger --help
Usage: ledger <command> [flags]
Commands:
  refund     Refund an order
  review     Weekly review from a dump
Flags:
  --help
  --version
  --json
  --config string
  --timeout duration (default 30s)
  --dry-run
  --endpoint string
  --verbose
  --no-color
  --experimental-split
I want examples for refund. A refund needs --order and an optional --dry-run.
--experimental-split is unfinished. Do not feature it.
The real binary name is ledger.

Steps

  1. Step 1

    Paste one command's help

    Copy the usage block for the command you care about, not the entire manual for a huge CLI. Add one line about which example a new user needs.

  2. Step 2

    Mark unfinished flags

    Name any flag that should stay out of the examples. The rewriter will not advertise it.

  3. Step 3

    Paste the prompt

    You get three examples a person can copy, a short list of flags that matter, and the flags you hid.

  4. Step 4

    Replace the examples in the help or the README

    Put the examples above the flag dictionary. Run one of them with --dry-run if that flag exists, so the docs are not fiction.

What you get

What you put in and what you get out

When to use it

Use it when your --help lists forty flags alphabetically and the one command a person needs to copy is not there.

When to skip it

It does not run your CLI. It will not invent subcommands, so paste the real help output.

Sample run

0:00

The dump

ledger refund needs --order, optional --dry-run. A long flag list includes --experimental-split, which they said is unfinished.

Full prompt

cli-help-rewriter.prompt.txt

You rewrite CLI help into examples a person will copy. You do not invent flags.

INPUTS
- Help text for one command.
- The example they want a new user to run.
- Flags that must not be featured.

RULES
- Three examples, copy-pasteable, using the binary and command from the help text.
- Every flag in an example must appear in the help text.
- Do not feature a flag they banned.
- If a required flag is obvious from the help, the first example includes it.
- Do not invent a default, a subcommand, or an example that needs a secret. Use placeholders like ORDER_ID.
- After the examples, list "flags that matter" (the ones you used) and "leave in the dictionary" (the rest).
- If the help is too broad (many unrelated commands), ask them to paste one command and stop.

OUTPUT
## Examples
Three fenced commands, each with a one-line caption.

## Flags that matter
## Leave in the dictionary
## Not featured
Banned flags, or "None."

Copied it? Get the Friday roundup. Seven agents and one tip, once a week.

How it works

Help text is a dictionary. People need a sentence they can paste. You give it the help for one command and the example you wish it had led with. It returns three examples using only flags from the paste, then a short list of the flags that belong in those examples.

Unfinished flags stay out. The rewriter does not invent a subcommand or a default you did not show. The binary name is the one you typed.

Put the examples above the flag list. If a dry run exists, run it. A documented command that fails on a clean machine is worse than a short help text.

Questions about CLI Help Rewriter

Where do the examples go?

At the top of --help, in the README, or in the docs landing page. Three copy-paste examples cover most people who open help.

Why hide some flags?

Experimental and internal flags in the main list make the useful ones harder to find. It marks them do-not-feature rather than deleting them.

Is CLI Help Rewriter free?

Yes. The prompt is free to copy, download, and reuse under CC-BY-4.0. There is no sign-up on One Agent a Day. You only need access to a chat model such as ChatGPT, Claude and Gemini.

Which AI tools does CLI Help Rewriter work in?

It was written for ChatGPT, Claude and Gemini. It is a plain-text prompt, so any capable chat model can run it. Paste the prompt first, then your input.

What do I paste into CLI Help Rewriter?

Paste one command's help. Copy the usage block for the command you care about, not the entire manual for a huge CLI. Add one line about which example a new user needs.

Compare and find more

Share this agent

CLI Help Rewriter — You put in $ ledger --help. You get out Hidden. Free from One Agent a Day.

Share on XShare on LinkedIn
Was this useful?

A yes or no is enough. The note stays on this server's log.

Friday email

The week’s 7 agents, in one email

Every Friday. Seven free prompts, one tip, one “paste this first.” Unsubscribe anytime.

One email, every Friday. Confirm on the next page. Unsubscribe anytime.

The daily agent stays free. Pro waitlist is a separate list, and it is not open yet.

Friday email

The week’s 7 agents, in one email

Every Friday. Seven free prompts, one tip, one “paste this first.” Unsubscribe anytime.

One email, every Friday. Confirm on the next page. Unsubscribe anytime.