diff options
author | zwbetz <zwbetz@gmail.com> | 2019-08-17 00:15:07 +0300 |
---|---|---|
committer | zwbetz <zwbetz@gmail.com> | 2019-08-17 00:15:07 +0300 |
commit | 698fe6ae491b1c7aa06014896e19dd9c73ddf538 (patch) | |
tree | 268e247d199de23cd32b0c36f8db0467f81d2026 | |
parent | 54c8f3bc4bece86ff6a66ecc9dcf756cc1b2fd2f (diff) |
fix issue per https://github.com/gohugoio/hugoThemes/issues/682
-rw-r--r-- | README.md | 4 | ||||
-rw-r--r-- | exampleSite/content/post/hugoisforlovers.md | 2 | ||||
-rw-r--r-- | exampleSite/content/post/migrate-from-jekyll.md | 2 | ||||
-rw-r--r-- | exampleSite/content/post/papercss-shortcodes/index.md | 2 | ||||
-rw-r--r-- | exampleSite/content/post/papercss-typography.md | 2 | ||||
-rw-r--r-- | layouts/partials/post-list.html | 7 | ||||
-rw-r--r-- | netlify.toml | 4 |
7 files changed, 12 insertions, 11 deletions
@@ -76,12 +76,12 @@ toc: false ## Disable summary for a blog post -The homepage blog post listing shows a summary for each post. To disable this for an individual post set `summary` to `false`. For example: +The homepage blog post listing shows a summary for each post. To disable this for an individual post set `show_summary` to `false`. For example: ``` --- title: "My page with some stellar content" -summary: false +show_summary: false --- ``` diff --git a/exampleSite/content/post/hugoisforlovers.md b/exampleSite/content/post/hugoisforlovers.md index c216902..1af4ba5 100644 --- a/exampleSite/content/post/hugoisforlovers.md +++ b/exampleSite/content/post/hugoisforlovers.md @@ -14,7 +14,7 @@ categories = [ ] series = ["Hugo 101"] author = "Hugo Authors" -summary = false +show_summary = false +++ ## Step 1. Install Hugo diff --git a/exampleSite/content/post/migrate-from-jekyll.md b/exampleSite/content/post/migrate-from-jekyll.md index c238114..6984063 100644 --- a/exampleSite/content/post/migrate-from-jekyll.md +++ b/exampleSite/content/post/migrate-from-jekyll.md @@ -8,7 +8,7 @@ series: - Hugo 101 aliases: - /blog/migrate-from-jekyll/ -summary: false +show_summary: false --- ## Move static content to `static` diff --git a/exampleSite/content/post/papercss-shortcodes/index.md b/exampleSite/content/post/papercss-shortcodes/index.md index 50b12b4..fb58740 100644 --- a/exampleSite/content/post/papercss-shortcodes/index.md +++ b/exampleSite/content/post/papercss-shortcodes/index.md @@ -2,7 +2,7 @@ title: "Papercss Shortcodes" date: 2019-02-26T13:50:01-06:00 tags: [shortcodes] -summary: false +show_summary: false --- ## border diff --git a/exampleSite/content/post/papercss-typography.md b/exampleSite/content/post/papercss-typography.md index 3e39d16..13d4871 100644 --- a/exampleSite/content/post/papercss-typography.md +++ b/exampleSite/content/post/papercss-typography.md @@ -2,7 +2,7 @@ title: "PaperCSS Typography" date: 2019-02-22T20:53:58-06:00 tags: [typography, markdown] -summary: false +show_summary: false --- ## Headings diff --git a/layouts/partials/post-list.html b/layouts/partials/post-list.html index 9301122..7f0e2f9 100644 --- a/layouts/partials/post-list.html +++ b/layouts/partials/post-list.html @@ -1,11 +1,12 @@ <h1>{{ .Title }}</h1> -{{ range where .Pages.ByPublishDate.Reverse "Section" "post" }} - <h2 class="post-list {{ if ne .Params.summary false }}summary{{ end }}"> +{{ $pages := where site.RegularPages "Type" "in" site.Params.mainSections }} +{{ range $pages.ByPublishDate.Reverse }} + <h2 class="post-list {{ if ne .Params.show_summary false }}summary{{ end }}"> <a href="{{ .Permalink }}"> {{ .Title }} </a> </h2> - {{ if ne .Params.summary false }} + {{ if ne .Params.show_summary false }} {{ .Summary }} {{ end }} {{ end }}
\ No newline at end of file diff --git a/netlify.toml b/netlify.toml index a1d166f..6042fb1 100644 --- a/netlify.toml +++ b/netlify.toml @@ -3,6 +3,6 @@ command = "cd exampleSite && hugo --gc --themesDir ../.." [build.environment] - HUGO_VERSION = "0.54.0" + HUGO_VERSION = "0.57.1" HUGO_THEME = "repo" - HUGO_BASEURL = "https://papercss-hugo-theme.netlify.com/"
\ No newline at end of file + HUGO_BASEURL = "https://papercss-hugo-theme.netlify.com/" |