I tried setting up a Hugo site a couple of years ago but failed. So I’m making a new attempt … but I seem to fail on the most basic stuff.
I better start with a description of the site as I imagine it. The site should have
-
navigation in two languages (Swedish/English)
-
the blog section will have posts in any of two languages but there will no translation of individual posts. In other words I expect to see a listing of posts in both languages.
-
a number of “standard pages” (about, work, etc), these will be in both languages
-
a number of sections with different types of content. I hope to be able to fix the layouts for these sometime in the future - when I hopefully have learned how Hugo works. The language of these sections will be mixed (some pages in Swedish, some in English)
I made an attempt to test my idea to see if everything worked as I hoped. I used this content (shortened to keep the listing short)
content:
examplesection:
_index.md
test.md
pages:
en:
about.md
sv:
about.md
posts:
_index.md
test.md
Unfortunately, I didn’t get the expected result (from my point of view ):
public:
css:
en:
404.html
about:
index.html
images:
avatar.jpg
index.html
sitemap.xml
sv:
404.html
about:
index.html
I had expected to find a examplesection
folder there somewhere, but I didn’t so I assume I’m doing something stupid. I should perhaps add that I have contentDir
set to "content/pages/en"
and "content/pages/sv"
for respective language.
In short I’m stumbling around trying to figure out how to organize my content. I would be really grateful if someone could point me in the correct direction for how to do this - unfortunately I didn’t understand how to apply the info in the docs to this situation.