DIsable folder creation for every content file

Hi i used an old version of hugo many years ago that converted a markdown file to an html file. Now it creates a directory with an index.html file for everything. Is there a way to disable this functionality as im using hugo to generate a large amount of email template files so the directories are unneeded.

So for example:
I want:

  • public/
    • sub-folder/
      • email-1.html
      • email-2.html

and dont want

  • public/
    • sub-folder/
      • email-1/
        • index.html
      • email-2/
        • index.html

Thanks for help

Read this :slight_smile:

Add render: never to everything you don’t want to be built and everything should be fine.

Or, if you have a larger productions script, just delete everything you don’t want to exist in public after creation.

Also have a look at uglyurls: https://gohugo.io/content-management/urls/#ugly-urls

1 Like

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