Posts randomly missing

Hi,
I’m a complete beginner with HUGO, but I tried searching online, read the FAQ, looked at this forum but couldn’t find a solution.

I have a very WIP site and the list page under /projects (code here) behaves very unpredictably. When rebuilding almost always some posts go missing from the list. If I change something in the post it shows up but then another goes missing. I checked all the syntax and it looks fine to me.
There is probably a much better way to list the subfolders in the template as well, but I don’t know where to go with this problem.
What am I missing?

You need to start by doing this:

mv content/index.md content/_index.md

But your projects/list.html template has a lot of issues.

1 Like

Hey aronkvh

I experienced something similar. Apparently, Hugo recognizes where posts are located by identifying which folder does not have index.md or _index.md.

Solution for me was to put an index.md to every folder except where the posts were located.

Have a look at this screenshot:

All pages have an index.md except posts. It can be a blank index.md for a page you don’t need, but I assume that it must exist for Hugo to make the distinction.

I hope this solution helps.

EDIT 1: Added screenshot, modified text to increase clarity of the answer.

No.

Per your screen capture above, you just made resume/en and resume/tr inaccessible.

https://gohugo.io/content-management/page-bundles/#comparison

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.