Skip to content

breaking change: the bare command introduces the tool - #5

Merged
obarlik merged 1 commit into
mainfrom
standards/bare-invocation
Aug 29, 2026
Merged

obarlik merged 1 commit into
mainfrom
standards/bare-invocation

Conversation

@obarlik

@obarlik obarlik commented Aug 29, 2026

Copy link
Copy Markdown
Member

One rule for TOOL.md §8, with its incident.

Typing a tool's name with no arguments is a reader asking what it is. Both Codechu tools answered with the argument parser's two-line error on stderr, exit 2 — naming cmd, spec, paths: internal dests, not anything a stranger could act on. For a tool whose stated manner is to refuse clearly and say what is missing, that was the one place it named an implementation detail at a person, and it was the first contact.

Bare invocation now means: the mark and the command list on stdout, exit 0. A wrong command or a missing flag stays an error on stderr with a non-zero exit — the distinction §2 already asks for, applied to the entry itself.

Both tools met a reader who typed their name with the argument
parser's error on stderr and exit 2, naming an internal dest as the
missing thing. That is the first contact a stranger has, and it was a
failure that pointed at a variable name.
Copilot AI lite review requested due to automatic review settings August 29, 2026 15:23
@obarlik
obarlik merged commit c6a2512 into main Aug 29, 2026
1 check passed
@obarlik
obarlik deleted the standards/bare-invocation branch August 29, 2026 15:24

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the Codechu tool conventions documentation to define how a CLI tool should behave when invoked with no arguments, treating it as an introduction/help entrypoint rather than an error—aligning stdout/stderr and exit code semantics with the broader CLI contract described in the document.

Changes:

  • Adds a new rule stating that bare invocation (tool with no args) should print the mark + command list to stdout and exit 0.
  • Documents the motivating incident where the argument parser surfaced internal dest names (e.g., cmd) and exited with code 2 on first contact.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants