Hi!
I work with Hugo for a small year now. I’ve read many docs and learned alot!
At this moment I’m in production of a multilingual website where there seems to be missing/off with the way I configured it or how Hugo parses the static pages.
If I run hugo —ignoreCache —verbose —debug
it sometimes creates content in a page and sometimes it doesn’t.
My folder structure
content
- dutch
- about
about.md
- english
- about
about.md
Both .md files include a url = ""
in the Front-matter
/dutch/about/about.md
url = "/nl/over-ons/"
/english/about/about.md
url = "/en/about/"
Building this as a static page with hugo
sometimes generates a /en/about/
page with my content in the <main>
element, including header and footer on the page.
But sometimes it generates only a <header>
and <footer>
with an empty <main>
.
This is not the case with the /nl/about/
page.
With all the different pages in this website (also multilingual) nothing seems to be incorrect.
config.toml
title = "My theme name"
theme = "themename"
baseURL = "/"
defaultContentLanguageInSubdir = true
defaultContentLanguage = "nl"
languageCode = "nl-NL"
MetaDataFormat = "toml"
enableRobotsTXT = true
[params]
nl_description = "A dutch description."
en_description = "A english description."
[sitemap]
changefreq = "monthly"
filename = "sitemap.xml"
priority = 0.5
[languages]
[languages.nl]
contentDir = "content/dutch"
staticDir = "static"
languageName = "Nederlands"
weight = 20
[languages.en]
contentDir = "content/english"
staticDir = "static"
languageName = "English"
weight = 10
[blackfriday]
extensionsmask = ["autoHeaderIds"]
I’m hoping something is off in my configuration and someone could point this out.
Also I hope I’ve given enough information, if not please let me know.
Below my current Hugo environment.
Hugo Static Site Generator v0.55.6-A5D4C82D2/extended darwin/amd64 BuildDate: 2019-05-18T08:06:24Z
GOOS="darwin"
GOARCH="amd64"
GOVERSION="go1.12.2"
Thanks in advance!