argLabel
<name>, [file], [names...]: an argument as usage shows it.
import { fallback } from "#codebase/tcmts/cli/help"; import type { ParamShape } from "#codebase/tcmts/cli/help"; export function argLabel(p: ParamShape): string { const n = `${p.name}${p.cardinality === "many" ? "..." : ""}`; return fallback(p) ? `[${n}]` : `<${n}>`; }