From 604739c5f54e05cdf3eaa658c75dd64e7867e987 Mon Sep 17 00:00:00 2001 From: Christian Nunciato Date: Fri, 14 Jun 2019 10:22:38 -0700 Subject: [PATCH 1/2] Add RSS for the blog Signed-off-by: Christian Nunciato --- config.toml | 16 +++++++++++----- layouts/blog/rss.xml | 29 +++++++++++++++++++++++++++++ layouts/partials/head.html | 36 +++++++++++++++++++----------------- 3 files changed, 59 insertions(+), 22 deletions(-) create mode 100644 layouts/blog/rss.xml diff --git a/config.toml b/config.toml index 746a8cc34c85..013e403a497c 100644 --- a/config.toml +++ b/config.toml @@ -2,7 +2,13 @@ baseURL = "https://pulumi.io/" languageCode = "en-us" title = "Pulumi" -disableKinds = ["category", "RSS"] +disableKinds = ["category", "taxonomyTerm"] +sectionPagesMenu = "main" +pygmentsCodeFences = true +pygmentsUseClasses = true + +[outputFormats.RSS] + baseName = "rss" pygmentsCodeFences = true pygmentsUseClasses = true @@ -10,12 +16,12 @@ pygmentsUseClasses = true sectionPagesMenu = "main" [taxonomies] - author = "authors" - tag = "tags" + author = "authors" + tag = "tags" [permalinks] - authors = "/blog/author/:slug/" - tags = "/blog/tag/:slug/" + authors = "/blog/author/:slug/" + tags = "/blog/tag/:slug/" [blackfriday] fractions = false diff --git a/layouts/blog/rss.xml b/layouts/blog/rss.xml new file mode 100644 index 000000000000..66acbe4b8701 --- /dev/null +++ b/layouts/blog/rss.xml @@ -0,0 +1,29 @@ + + + Pulumi Blog + {{ .Permalink }} + Infrastructure as Code for AWS, Azure, Google Cloud, including Kubernetes, Serverless, Containers, for Developers and DevOps. + {{ .Site.LanguageCode }} + {{ .Date.Format "Mon, 02 Jan 2006" | safeHTML }} + {{ range where .Data.Pages "Type" "in" "blog" }} + + {{ .Title }} + {{ .Permalink }} + {{ .Date.Format "Mon, 02 Jan 2006" | safeHTML }} + {{ .Permalink }} + {{ .Summary | html }} + {{ range $id := .Params.authors }} + {{ $author := index $.Site.Data.team.team $id }} + {{ if $author }} + {{ $author.name }} + {{ end }} + {{ end }} + {{ range $tag := .Params.tags }} + {{ if $tag }} + {{ $tag }} + {{ end }} + {{ end }} + + {{ end }} + + diff --git a/layouts/partials/head.html b/layouts/partials/head.html index adec9bb6a49d..b97827c2eba9 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -3,8 +3,9 @@ + {{ if isset .Params "redirect_to" }} - + {{ end }} + +