The command hugo new outputs front matter in the resulting file in alphabetical order.
Archetype:
---
foo: ""
bar: ""
---
Ouputs:
---
bar: ""
foo: ""
---
My expectation would be that the output would respect the order I created in the archetype.
While alphabetical enforces consistency, I think it’s important to control the order to suit the content, particularly for non-technical editors, and even more particularly for more complex content where there’s meaning to the hierarchy (for instance, more important keys, like “title” at the top).
I don’t see any indication or flag for this in the docs. Surprised not to find anything in the forums on this either.
Is there a way to get what I want, or is this a feature request?
Apologies for the duplicate. Doesn’t seem to me the issues here on the forums addressed it precisely, but I hadn’t looked at the repo. I see the most relevant issue as https://github.com/spf13/hugo/issues/452 and at the moment it is “Please Contribute” so not on the radar.