Guidance - GetTerminus/blog GitHub Wiki

Introduction

This section will give you some details to help you start your blog. The contents of the blog is written in markdown and then its rendered output is html. When you start your blog you will notice the Front Matter default to title, date, and draft. This is metadata about your blog. Also, you can tag your blog as well.

Procedure

At the root of your blog perform an ls in the terminal and there should be:

archetypes content layouts resources themes

config.toml data public static

In the terminal, perform hugo new posts/my-first-post.md. Go to your my-first-post.md. By default the Front Matter is yaml. Let us change that and make it toml to keep it consistent with the config.toml. What you do is change --- to +++ and that is it.

In the Example below let's get rid of the date in the Front Matter. Furthermore, let's throw in some tags as well so we can group and organize our blog. Additionally, I created five keys, which if entered will be rendered output. The keys are:

author, email, linkedin, github, twitter

Example

+++
title: "Foo"
draft: "true"
author: "chue"
email: "[email protected]"
tags = ["go", "sli", "slo"]
+++

Now, you can run the command hugo server -D, go to your localhost and you will notice the Title, Author, Email, and the tags you have entered.

Conclusion

To sum up, I hope this guidance will help you on your journey to blog efficiently using the predefined keys correctly for the Front Matter. Have fun blogging!