Documentation
¶
Overview ¶
Package report renders mode summaries to the user through clog: per-marker lines with smart file:line hyperlinks, plus a closing summary. It is the CLI-edge presentation layer - the engine returns data, report turns it into output. The logger is injected so output is testable and the pure core stays terminal-free.
Index ¶
- func Annotate(logger *clog.Logger, summary mode.AnnotateSummary, write bool)
- func Format(logger *clog.Logger, summary mode.FormatSummary, dry bool)
- func GitHub(w io.Writer, summary mode.Summary, dryRun bool)
- func Lint(logger *clog.Logger, summary mode.Summary, detail output.Mode)
- func Run(logger *clog.Logger, summary mode.Summary, dryRun bool, detail output.Mode)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Annotate ¶
func Annotate(logger *clog.Logger, summary mode.AnnotateSummary, write bool)
Annotate renders the annotations clover added (or, in preview, would add), then a closing summary. A written line reads "Annotated"/"Reannotated" (🌱/♻️); in preview - the default, without --write - nothing is written, so each reads "Would add"/"Would update" and both it and the summary log at the Dry level.
func Format ¶
func Format(logger *clog.Logger, summary mode.FormatSummary, dry bool)
Format renders the directives that were (or, when not writing, would be) reformatted, then a closing summary. A written line reads "Formatted" (✨); with dry set - under --check or --dry-run - nothing is written, so each line reads "Would format" and both it and the summary log at the Dry level.
func GitHub ¶
GitHub writes each actionable result as a GitHub Actions annotation, so a run or lint surfaces inline on a pull request: a failure or pin-verification mismatch as ::error, a skip or available update as ::warning. file:line locate the marker. Clean results emit nothing.
func Lint ¶
Lint renders each invalid or skipped marker and a closing summary. In wide output, valid markers are reported too.
Types ¶
This section is empty.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package github builds GitHub Actions workflow-command annotations - the ::error/::warning/::notice lines a workflow parses from a step's output to surface a message inline on a pull request.
|
Package github builds GitHub Actions workflow-command annotations - the ::error/::warning/::notice lines a workflow parses from a step's output to surface a message inline on a pull request. |