niklasfasching / go-org

Org mode parser with html & pretty printed org rendering. also shitty static site generator.
https://niklasfasching.github.io/go-org/
MIT License
354 stars 49 forks source link

Add support for _build front-matter (Hugo 0.65+) #34

Closed olif closed 4 years ago

olif commented 4 years ago

https://gohugo.io/news/0.65.0-relnotes/

niklasfasching commented 4 years ago

Do you have an idea how this should look? as it's nested I feel like maybe there's no clean way to do it with keywords and yaml is the right option.

olif commented 4 years ago

No I don't see a straightforward way to implement support for yaml (hierarchical data) in org-syntax. Perhaps one way could be to define the front-matter within and #+BEGIN_SRC yaml instead.

The exact same issue is created for ox-hugo by the maintainer.

niklasfasching commented 4 years ago

last time I checked hugo supported yaml frontmatter in org files. If that's still the case I don't think anything needs to be done. yaml in src block sounds like it could be the next best option but I'd avoid it if raw yaml frontmatter works.

olif commented 4 years ago

Aha, was not aware of that yaml frontmatter works in org-mode files but I can confirm now that it does. Thank you.