lint/configured/hugo
The Hugo build treats warnings as errors
Implements lint/configured for hugo.
| Severity | warning |
| Tiers | 1, 2 |
| Stacks | hugo |
| Scope | each |
| Kind | outcome |
| Source | library v0.3.1 |
| Selected by | fleetlint-recommended@v0.3.1 |
Requirement
The task runner’s lint or build target, a hook, or CI runs hugo --panicOnWarning so a missing layout, a broken ref or a deprecated setting fails the build instead of printing a warning nobody reads.
Why
Hugo prints warnings for broken references and deprecated configuration and still exits 0; the flag is the only thing that turns them into a failed build.
Fix
Add --panicOnWarning to the hugo invocation in the lint or build target (see https://fleetlint.org/stacks/#hugo--static-sites).
Agent instruction: Add –panicOnWarning to the hugo build in the lint or build target and fix the warnings it surfaces instead of removing the flag.
See: https://fleetlint.org/baseline/#static-analysis, https://fleetlint.org/stacks/#hugo--static-sites
Generated by fleetlint docs from catalog v0.3.1.