HUGO-BUILD(1)
π HUGO-BUILD(1) β the Hugo Manual, bestie edition π
okay so this is the hugo-build page from the Hugo Manual, and honestly? it's a whole vibe. buckle up π¦
β¨ NAME β¨
hugo-build β build your project. that's it. that's the tweet. π
πΈ SYNOPSIS πΈ
hugo build [flags]
π§ DESCRIPTION π§
build is the main character command, fr fr β it's the one you use to build your Hugo project. π
Hugo is a Fast and Flexible Static Site Generator built with love by spf13 and friends in Go. no cap, that's the actual description, we don't make the rules. π
Complete documentation is available at https://gohugo.io/. go read it, it's giving β¨reference materialβ¨.
π OPTIONS π
so many flags. all of them iconic. here we go:
-b,--baseURL=""β hostname (and path) to the root, e.g.https://spf13.com/. your site's home address π-D,--buildDrafts[=false]β include content marked as draft. let the WIPs see the light of day π-E,--buildExpired[=false]β include expired content. resurrect it, lowkey π-F,--buildFuture[=false]β include content withpublishdatein the future. time travel behavior, honestly β°--cacheDir=""β filesystem path to cache directory--cleanDestinationDir[=false]β remove stale files from destination. declutter era π§Ή--clock=""β set the clock used by Hugo, e.g.--clock 2021-11-06T22:30:00.00+09:00--config=""β config file (default ishugo.yaml|json|toml). yup, all three, pick your fighter π--configDir="config"β config dir-c,--contentDir=""β filesystem path to content directory-d,--destination=""β filesystem path to write files to--disableKinds=[]β disable different kind of pages (home, RSS etc.). sometimes you just don't want a homepage, and that's valid π«Ά--enableGitInfo[=false]β add Git revision, date, author, andCODEOWNERSinfo to the pages-e,--environment=""β build environment--forceSyncStatic[=false]β copy all files when static is changed. notice the period, it's in the original, we keep it, periodt π--gc[=false]β enable to run some cleanup tasks (remove unused cache files) after the build. self-care for your disk π§Ό-h,--help[=false]β help for build--ignoreCache[=false]β ignore the configured file caches--ignoreVendorPaths=""β ignores any_vendorfor module paths matching the given Glob pattern-l,--layoutDir=""β filesystem path to layout directory--logLevel=""β log level (debug|info|warn|error)--minify[=false]β minify any supported output format (HTML, XML etc.). shrink it, slay it βοΈ--noBuildLock[=false]β don't create.hugo_build.lockfile--noChmod[=false]β don't sync permission mode of files--noTimes[=false]β don't sync modification time of files--panicOnWarning[=false]β panic on firstWARNINGlog. dramatic? yes. useful? also yes, sometimes π--poll=""β set this to a poll interval, e.g--poll 700ms, to use a poll based approach to watch for file system changes--printI18nWarnings[=false]β print missing translations--printMemoryUsage[=false]β print memory usage to screen at intervals--printPathWarnings[=false]β print warnings on duplicate target paths etc.--printUnusedTemplates[=false]β print warnings on unused templates. notice the period again. we're consistent. π--quiet[=false]β build in quiet mode. shhh π€«--renderSegments=[]β named segments to render (configured in thesegmentsconfig)-M,--renderToMemory[=false]β render to memory (mostly useful when running the server)-s,--source=""β filesystem path to read files relative from--templateMetrics[=false]β display metrics about template executions. numbers!! stats!! π--templateMetricsHints[=false]β calculate some improvement hints when combined with--templateMetrics. bestie duo fr fr π«Ά-t,--theme=[]β themes to use (located in/themes/THEMENAME/)--themesDir=""β filesystem path to themes directory--trace=""β write trace to file (not useful in general). the original said it, not me, ngl π-w,--watch[=false]β watch filesystem for changes and recreate as needed. live-reload energy, we're obsessed π
π¦ SEE ALSO π¦
hugo(1)β the parent, the icon, the moment π
that's the whole page bestie, every flag accounted for, no skips, no cap. now go build something pretty πΈ
hugo-build, from Hugo 0.169.0, dated Oct 2026 β mwah, xoxo, go touch some static files πβ¨
π¦ where this page comes from
- arch rolling: hugo 0.169.0-1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms