theme: convert front matter to TOML #52

remove date field
This commit is contained in:
Sören Weber 2021-08-25 13:33:29 +02:00
parent 96c98986a4
commit 15cfc82ddb
No known key found for this signature in database
GPG key ID: 07D17FF580AE7589
44 changed files with 153 additions and 170 deletions

View file

@ -1,9 +1,8 @@
+++ +++
title = "{{ replace .Name "-" " " | title }}"
date = {{ .Date }}
weight = 5
chapter = true chapter = true
pre = "<b>X. </b>" pre = "<b>X. </b>"
title = "{{ replace .Name "-" " " | title }}"
weight = 5
+++ +++
### Chapter X ### Chapter X

View file

@ -1,6 +1,5 @@
+++ +++
title = "{{ replace .Name "-" " " | title }}" title = "{{ replace .Name "-" " " | title }}"
date = {{ .Date }}
weight = 5 weight = 5
+++ +++

View file

@ -1,6 +1,6 @@
--- +++
title: "Relearn Theme for Hugo" title = "Relearn Theme for Hugo"
--- +++
# Hugo Relearn Theme # Hugo Relearn Theme

View file

@ -1,9 +1,9 @@
--- +++
title: Basics chapter = true
weight: 5 pre = "<b>1. </b>"
pre: "<b>1. </b>" title = "Basics"
chapter: true weight = 5
--- +++
### Chapter 1 ### Chapter 1

View file

@ -1,8 +1,7 @@
--- +++
date: 2016-04-09T16:50:16+02:00 title = "Configuration"
title: Configuration weight = 20
weight: 20 +++
---
## Global site parameters ## Global site parameters

View file

@ -1,8 +1,7 @@
--- +++
date: 2016-04-09T16:50:16+02:00 title = "Customization"
title: Customization weight = 25
weight: 25 +++
---
**Hugo-theme-relearn** has been built to be as configurable as possible by defining multiple [partials](https://gohugo.io/templates/partials/) **Hugo-theme-relearn** has been built to be as configurable as possible by defining multiple [partials](https://gohugo.io/templates/partials/)

View file

@ -1,6 +1,5 @@
--- +++
date: 2021-08-23T16:50:16+02:00 title = "History"
title: History weight = 30
weight: 30 +++
---
{{% include "basics/CHANGELOG.md" %}} {{% include "basics/CHANGELOG.md" %}}

View file

@ -1,7 +1,7 @@
--- +++
title: Installation title = "Installation"
weight: 15 weight = 15
--- +++
The following steps are here to help you initialize your new website. If you don't know Hugo at all, we strongly suggest you learn more about it by following this [great documentation for beginners](https://gohugo.io/overview/quickstart/). The following steps are here to help you initialize your new website. If you don't know Hugo at all, we strongly suggest you learn more about it by following this [great documentation for beginners](https://gohugo.io/overview/quickstart/).

View file

@ -1,7 +1,6 @@
--- +++
date: 2021-08-23T16:50:16+02:00 title = "Migration"
title: Migration weight = 17
weight: 17 +++
---
If you are coming from a previous version of the theme or even from the hugo-theme-learn. You may want to achieve old behaviour in case of an update. If you are coming from a previous version of the theme or even from the hugo-theme-learn. You may want to achieve old behaviour in case of an update.

View file

@ -1,8 +1,8 @@
--- +++
title: Requirements disableToc = true
weight: 10 title = "Requirements"
disableToc: true weight = 10
--- +++
Thanks to the simplicity of Hugo, this page is as empty as this theme needs requirements. Thanks to the simplicity of Hugo, this page is as empty as this theme needs requirements.

View file

@ -1,9 +1,9 @@
--- +++
title: Content chapter = true
weight: 10 pre = "<b>2. </b>"
chapter: true title = "Content"
pre: "<b>2. </b>" weight = 10
--- +++
### Chapter 2 ### Chapter 2

View file

@ -1,7 +1,7 @@
--- +++
title: Archetypes title = "Archetypes"
weight: 10 weight = 10
--- +++
Using the command: `hugo new [relative new content path]`, you can start a content file with the date and title automatically set. While this is a welcome feature, active writers need more: [archetypes](https://gohugo.io/content/archetypes/). Using the command: `hugo new [relative new content path]`, you can start a content file with the date and title automatically set. While this is a welcome feature, active writers need more: [archetypes](https://gohugo.io/content/archetypes/).
@ -19,11 +19,10 @@ It will create a page with predefined Front-Matter:
```toml ```toml
+++ +++
title = "{{ replace .Name "-" " " | title }}"
date = {{ .Date }}
weight = 5
chapter = true chapter = true
pre = "<b>X. </b>" pre = "<b>X. </b>"
title = "{{ replace .Name "-" " " | title }}"
weight = 5
+++ +++
### Chapter X ### Chapter X
@ -52,7 +51,6 @@ It will create a page with predefined Front-Matter:
```toml ```toml
+++ +++
title = "{{ replace .Name "-" " " | title }}" title = "{{ replace .Name "-" " " | title }}"
date = {{ .Date }}
weight = 5 weight = 5
+++ +++

View file

@ -1,8 +1,7 @@
--- +++
date: 2016-04-09T16:50:16+02:00 title = "Multilingual and i18n"
title: Multilingual and i18n weight = 30
weight: 30 +++
---
**Relearn theme** is fully compatible with Hugo multilingual mode. **Relearn theme** is fully compatible with Hugo multilingual mode.

View file

@ -1,7 +1,7 @@
--- +++
title: Icons and logos title = "Icons and logos"
weight: 27 weight = 27
--- +++
The Relearn theme for Hugo loads the [**Font Awesome**](https://fontawesome.com) library, allowing you to easily display any icon or logo available in the Font Awesome free collection. The Relearn theme for Hugo loads the [**Font Awesome**](https://fontawesome.com) library, allowing you to easily display any icon or logo available in the Font Awesome free collection.

View file

@ -1,8 +1,7 @@
--- +++
date: 2016-04-09T16:50:16+02:00 title = "Markdown syntax"
title: Markdown syntax weight = 15
weight: 15 +++
---
Let's face it: Writing content for the Web is tiresome. WYSIWYG editors help alleviate this task, but they generally result in horrible code, or worse yet, ugly web pages. Let's face it: Writing content for the Web is tiresome. WYSIWYG editors help alleviate this task, but they generally result in horrible code, or worse yet, ugly web pages.

View file

@ -1,8 +1,7 @@
--- +++
date: 2016-04-09T16:50:16+02:00 title = "Menu extra shortcuts"
title: Menu extra shortcuts weight = 25
weight: 25 +++
---
You can define additional menu entries or shortcuts in the navigation menu without any link to content. You can define additional menu entries or shortcuts in the navigation menu without any link to content.

View file

@ -1,8 +1,7 @@
--- +++
date: 2016-04-09T16:50:16+02:00 title = "Pages organization"
title: Pages organization weight = 5
weight: 5 +++
---
In **Hugo**, pages are the core of your site. Once it is configured, pages are definitely the added value to your documentation site. In **Hugo**, pages are the core of your site. Once it is configured, pages are definitely the added value to your documentation site.
@ -51,10 +50,10 @@ You can define any HTML as prefix for the menu. In the example below, it's just
```markdown ```markdown
+++ +++
title = "Basics"
chapter = true chapter = true
weight = 5
pre = "<b>1. </b>" pre = "<b>1. </b>"
title = "Basics"
weight = 5
+++ +++
### Chapter 1 ### Chapter 1
@ -91,7 +90,7 @@ hugo new site <new_project>
## Front Matter configuration ## Front Matter configuration
Each Hugo page has to define a [Front Matter](https://gohugo.io/content/front-matter/) in *yaml*, *toml* or *json*. Each Hugo page has to define a [Front Matter](https://gohugo.io/content/front-matter/) in *toml*, *yaml* or *json*. This site will use *toml* in all cases.
**Hugo-theme-relearn** uses the following parameters on top of Hugo ones : **Hugo-theme-relearn** uses the following parameters on top of Hugo ones :

View file

@ -1,8 +1,7 @@
--- +++
date: 2020-06-01T13:31:12+01:00 title = "Code highlighting"
title: Code highlighting weight = 16
weight: 16 +++
---
Relearn theme uses [Hugo's built-in syntax highlighting](https://gohugo.io/content-management/syntax-highlighting/) for code. Relearn theme uses [Hugo's built-in syntax highlighting](https://gohugo.io/content-management/syntax-highlighting/) for code.

View file

@ -1,9 +1,8 @@
--- +++
date: 2018-11-29T08:41:44+01:00 tags = ["documentation", "tutorial"]
title: Tags title = "Tags"
weight: 40 weight = 40
tags: ["documentation", "tutorial"] +++
---
*Relearn theme* supports one default taxonomy of Hugo: the *tag* feature. *Relearn theme* supports one default taxonomy of Hugo: the *tag* feature.
@ -11,13 +10,12 @@ tags: ["documentation", "tutorial"]
Just add tags to any page: Just add tags to any page:
```markdown ```toml
--- +++
date: 2018-11-29T08:41:44+01:00 tags = ["tutorial", "theme"]
title: Theme tutorial title = "Theme tutorial"
weight: 15 weight = 15
tags: ["tutorial", "theme"] +++
---
``` ```
## Behavior ## Behavior

View file

@ -1,7 +1,7 @@
--- +++
title: Credits disableToc = true
disableToc: true title = "Credits"
--- +++
## Contributors ## Contributors

View file

@ -1,9 +1,8 @@
--- +++
date: 2016-04-09T16:50:16+02:00 pre = "<b>3. </b>"
title: Shortcodes title = "Shortcodes"
pre: "<b>3. </b>" weight = 15
weight: 15 +++
---
Hugo uses Markdown for its simple content format. However, there are a lot of things that Markdown doesnt support well. You could use pure HTML to expand possibilities. Hugo uses Markdown for its simple content format. However, there are a lot of things that Markdown doesnt support well. You could use pure HTML to expand possibilities.

View file

@ -1,7 +1,7 @@
--- +++
title: Attachments description = "The Attachments shortcode displays a list of files attached to a page."
description : "The Attachments shortcode displays a list of files attached to a page." title = "Attachments"
--- +++
The Attachments shortcode displays a list of files attached to a page. The Attachments shortcode displays a list of files attached to a page.

View file

@ -1,7 +1,7 @@
--- +++
title: Button description = "Nice buttons on your page."
description : "Nice buttons on your page." title = "Button"
--- +++
A button is a just a clickable button with optional icon. A button is a just a clickable button with optional icon.

View file

@ -1,8 +1,8 @@
--- +++
title : Children alwaysopen = false
description : List the child pages of a page description = "List the child pages of a page"
alwaysopen : false title = "Children"
--- +++
Use the children shortcode to list the child pages of a page and the further descendants (children's children). By default, the shortcode displays links to the child pages. Use the children shortcode to list the child pages of a page and the further descendants (children's children). By default, the shortcode displays links to the child pages.

View file

@ -1,7 +1,7 @@
+++ +++
title = "page 1"
description = "This is a demo child page"
alwaysopen = false alwaysopen = false
description = "This is a demo child page"
title = "page 1"
+++ +++
This is a demo child page This is a demo child page

View file

@ -1,6 +1,6 @@
+++ +++
title = "page 1-1"
description = "This is a demo child page" description = "This is a demo child page"
title = "page 1-1"
+++ +++
This is a demo child page This is a demo child page

View file

@ -1,6 +1,6 @@
+++ +++
title = "page 1-1-1"
description = "This is a demo child page" description = "This is a demo child page"
title = "page 1-1-1"
+++ +++
This is a demo child page This is a demo child page

View file

@ -1,6 +1,6 @@
+++ +++
title = "page 1-1-1-1"
description = "This is a demo child page" description = "This is a demo child page"
title = "page 1-1-1-1"
+++ +++
This is a demo child page This is a demo child page

View file

@ -1,6 +1,6 @@
+++ +++
title = "page 1-1-1-1-1"
description = "This is a demo child page" description = "This is a demo child page"
title = "page 1-1-1-1-1"
+++ +++
This is a demo child page This is a demo child page

View file

@ -1,6 +1,6 @@
+++ +++
title = "page 1-1-2"
description = "This is a demo child page" description = "This is a demo child page"
title = "page 1-1-2"
+++ +++
This is a demo child page This is a demo child page

View file

@ -1,6 +1,6 @@
+++ +++
title = "page 1-1-2-1"
description = "This is a demo child page" description = "This is a demo child page"
title = "page 1-1-2-1"
+++ +++
This is a demo child page This is a demo child page

View file

@ -1,6 +1,6 @@
+++ +++
title = "page 1-1-2-2"
description = "This is a demo child page" description = "This is a demo child page"
title = "page 1-1-2-2"
+++ +++
This is a demo child page This is a demo child page

View file

@ -1,7 +1,7 @@
+++ +++
title = "page 2"
description = ""
alwaysopen = false alwaysopen = false
description = ""
title = "page 2"
+++ +++
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod

View file

@ -1,6 +1,6 @@
+++ +++
title = "page test 3"
description = "This is a page test" description = "This is a page test"
title = "page test 3"
+++ +++
This is a test 3 demo child page This is a test 3 demo child page

View file

@ -1,7 +1,7 @@
+++ +++
title = "page 3"
description = "This is a demo child page"
alwaysopen = false alwaysopen = false
description = "This is a demo child page"
title = "page 3"
+++ +++
This is a demo child page, not displayed in the menu This is a demo child page, not displayed in the menu

View file

@ -1,8 +1,8 @@
+++ +++
title = "page 4" alwaysopen = false
description = "This is a demo child page" description = "This is a demo child page"
hidden = true hidden = true
alwaysopen = false title = "page 4"
+++ +++
This is a demo child page, not displayed in the menu This is a demo child page, not displayed in the menu

View file

@ -1,6 +1,6 @@
+++ +++
title = "page test"
description = "This is a page test" description = "This is a page test"
title = "page test"
+++ +++
This is a test demo child page This is a test demo child page

View file

@ -1,7 +1,7 @@
--- +++
title : Expand description = "Displays an expandable/collapsible section of text on your page"
description : "Displays an expandable/collapsible section of text on your page" title = "Expand"
--- +++
The Expand shortcode displays an expandable/collapsible section of text on your page. The Expand shortcode displays an expandable/collapsible section of text on your page.

View file

@ -1,7 +1,7 @@
--- +++
title: Include description = "Displays content from other markdown files"
description: "Displays content from other markdown files" title = "Include"
--- +++
The include shortcode includes other files from your project inside of the current file. This can even contain markdown and will be taken into account when generating the table of contents. The include shortcode includes other files from your project inside of the current file. This can even contain markdown and will be taken into account when generating the table of contents.

View file

@ -1,8 +1,7 @@
+++
--- description = "Generation of diagram and flowchart from text in a similar manner as markdown"
title : "Mermaid" title = "Mermaid"
description : "Generation of diagram and flowchart from text in a similar manner as markdown" +++
---
[Mermaid](https://mermaidjs.github.io/) is a library helping you to generate diagram and flowcharts from text, in a similar manner as Markdown. [Mermaid](https://mermaidjs.github.io/) is a library helping you to generate diagram and flowcharts from text, in a similar manner as Markdown.

View file

@ -1,7 +1,7 @@
--- +++
title: Notice description = "Disclaimers to help you structure your page"
description: "Disclaimers to help you structure your page" title = "Notice"
--- +++
The notice shortcode shows four types of disclaimers to help you structure your page. The notice shortcode shows four types of disclaimers to help you structure your page.

View file

@ -1,7 +1,7 @@
--- +++
title: Site param description = "Get value of site params variables in your page."
description : "Get value of site params variables in your page." title = "Site param"
--- +++
`siteparam` shortcode is used to help you print values of site params. `siteparam` shortcode is used to help you print values of site params.

View file

@ -1,7 +1,7 @@
--- +++
title: Tabbed views description = "Synchronize selection of content in different tabbed views"
description : "Synchronize selection of content in different tabbed views" title = "Tabbed views"
--- +++
Choose which content to see across the page. Very handy for providing code Choose which content to see across the page. Very handy for providing code
snippets for multiple languages or providing configuration in different formats. snippets for multiple languages or providing configuration in different formats.

View file

@ -1,7 +1,7 @@
--- +++
title: Showcase disableToc = true
disableToc: true title = "Showcase"
--- +++
#### [TAT](https://ovh.github.io/tat/overview/) by OVH #### [TAT](https://ovh.github.io/tat/overview/) by OVH
![TAT image](/images/showcase/tat.png?width=50pc) ![TAT image](/images/showcase/tat.png?width=50pc)