Skip to main content

Module render

Module render 

Source
Expand description

A stable text rendering of a clap tree.

Two guards read this. A golden snapshot in crates/cli pins the contract humans already type, so a refactor that re-spells a flag fails rather than ships. A drift check pins the agent-facing tree to the same rendering, so the two surfaces cannot diverge without a test saying so.

The format is for diffing, not for reading: one line per argument, fields in a fixed order, sorted, so a change shows up as the line that changed.

Functionsยง

diff
A line-level difference between two renderings.
tree
Render a whole command tree, one line per leaf argument.