Skip to content
framework8 active rulesVerified 2026-09-30

Hugo .gitignore Template

Hugo static site generator resources, public output, and cache. Generated and merged deterministically with upstream GitHub repository patterns to keep your repository clean of package directories, temporary build artifacts, and local environment files.

Interactive Stack Generator

Preconfigured with Hugo
Search for templates
Quick add:
Selected1
Hugo
Selected Templates (1)
.gitignore
8 rules
### Hugo ###
# Generated files by hugo
/public/
/resources/_gen/
/assets/jsconfig.json
hugo_stats.json
# Executable may be added to repository
hugo.exe
hugo.darwin
hugo.linux
# Temporary lock file while building
/.hugo_build.lock
15 lines•UTF-8
Deterministic

Raw Hugo .gitignore

Crawlable upstream source template
golang-hugo.gitignore•14 lines•UTF-8
# Generated files by hugo
/public/
/resources/_gen/
/assets/jsconfig.json
hugo_stats.json
# Executable may be added to repository
hugo.exe
hugo.darwin
hugo.linux
# Temporary lock file while building
/.hugo_build.lock

Key Pattern Breakdown

Build Outputs & Compiled Artifacts

Generated binary files, compilation targets, and distribution bundles that can be reliably reproduced from source.

/.hugo_build.lock

Source & Verification

License: CC0-1.0

Place this file in the root directory of your project as .gitignore. Changes take effect on newly added or untracked files.