Convert Hugo content from TOML to YAML

Convert you Hugo content from TOML to YAML

When you are using Azure DevOps and go in the portal to your REPO and look at the content you will see that DevOps doesn’t recognize the TOML format. But when you switch it to YAML you will get a nice table at the start op de page like understanding.

YAML inDevOps

With the following command you can convert your existing content to YAML:

hugo convert toYAML --output content_as_yaml

And look if everything is right when this is the case you can rename your current content directory to content.old and the content_as_yaml to content.

In your config.toml you have to put the line:

MetaDataFormat = "yaml"

Commit your changes in your DevOps REPO and push them you your DevOps REPO and your good to go.

Andre van den Berg
Andre van den Berg

Andre works with Azure, Office 365, Intune and automating things with PowerShell as a consultant at The Sourcing Company. He worked as a system/network administrator at Meyra for 18 years and helped people with everything related to IT while innovating the IT infrastructure at the same time. He enjoys attending meetups and events to learn new technologies, talk with interesting people and exchange stickers. He turned his hobby into his job and loves to blog, work on IoT projects at home and read books to his daughter.

comments powered by Disqus