From 708c99ab6534c306eb63f56e500c16927a9ae12c Mon Sep 17 00:00:00 2001 From: Joe Mooring Date: Mon, 23 Aug 2021 14:47:26 -0700 Subject: [PATCH 1/2] Create README.md --- README.md | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..ec0b841 --- /dev/null +++ b/README.md @@ -0,0 +1,3 @@ +# hugo-repro-missing-data + +See From 988a632d05f7d8e97f11617e3961ac7a61bc023d Mon Sep 17 00:00:00 2001 From: Joe Mooring Date: Mon, 23 Aug 2021 14:56:54 -0700 Subject: [PATCH 2/2] Add description field --- config.toml | 13 +++++++------ content/en/_index.md | 3 ++- content/zh_CN/_index.md | 3 ++- layouts/_default/home.html | 4 ++-- layouts/home.metadata.html | 4 ++-- 5 files changed, 15 insertions(+), 12 deletions(-) diff --git a/config.toml b/config.toml index 150b65c..4e5371b 100644 --- a/config.toml +++ b/config.toml @@ -4,26 +4,27 @@ title = 'My New Hugo Site' languageCode = "en" defaultContentLanguage = "en" +disableKinds = ['taxonomy','term','sitemap'] [languages] [languages.en] - title = "Repro" - languageName = "English" contentDir = "content/en" + languageName = "English" + title = "Repro" weight = 1 [languages.zh_CN] + contentDir = "content/zh_CN" + languageName = "简体中文" title = "Repro" weight = 2 - languageName = "简体中文" - contentDir = "content/zh_CN" [outputFormats] [outputFormats.metadata] baseName = "metadata" - mediaType = "text/html" isPlainText = true + mediaType = "text/html" notAlternative = true [outputs] - home = ["HTML", "metadata"] \ No newline at end of file + home = ["HTML", "metadata"] diff --git a/content/en/_index.md b/content/en/_index.md index c003a32..249a861 100644 --- a/content/en/_index.md +++ b/content/en/_index.md @@ -1,8 +1,9 @@ --- title: Title (en) +description: Description (en) summary: Summary (en) menu: main: weight: 1 ---- \ No newline at end of file +--- diff --git a/content/zh_CN/_index.md b/content/zh_CN/_index.md index 187bef8..7d733b5 100644 --- a/content/zh_CN/_index.md +++ b/content/zh_CN/_index.md @@ -1,8 +1,9 @@ --- title: Title (zh) +description: Description (zh) summary: Summary (zh) menu: main: weight: 1 ---- \ No newline at end of file +--- diff --git a/layouts/_default/home.html b/layouts/_default/home.html index 1e44d2b..980614d 100644 --- a/layouts/_default/home.html +++ b/layouts/_default/home.html @@ -4,8 +4,8 @@

Translations

{{ range .Site.Menus.main }} {{ $p := .Page }} {{ range $p.Translations}} -
  • {{ .Title }}, {{ .Summary }}
  • +
  • {{ .Title }}, {{ .Description }}, {{ .Summary }}
  • {{ end }} {{ end }} -{{ end }} \ No newline at end of file +{{ end }} diff --git a/layouts/home.metadata.html b/layouts/home.metadata.html index 8214a0d..066f37e 100644 --- a/layouts/home.metadata.html +++ b/layouts/home.metadata.html @@ -3,7 +3,7 @@

    Translations

    {{ range .Site.Menus.main }} {{ $p := .Page }} {{ range $p.Translations}} -
  • {{ .Title }}, {{ .Summary }}
  • +
  • {{ .Title }}, {{ .Description }}, {{ .Summary }}
  • {{ end }} {{ end }} - \ No newline at end of file +