rules/workflows/report.js

Developer reference: this page includes exported implementation details. BUILD authors should prefer the User API reference.

statusReport()

statusReport(units, { order, colors, summary })

Render { key, status, output? }[] as a report: one column-aligned, colored line per unit (sorted by status severity per order, then by key), then each unit's output block (if any), then summary(counts)'s line.

ParameterTypeDescription
unitsArray<{key: string, status: string, output?: string}>
optsobject
opts.orderstring[]Status values, most severe first.
opts.colorsRecord<string, "red""yellow"
opts.summary(counts: Record<string, number>) => string

Returns: string