Factor time format

master
Will Faught 2 years ago
parent 6815d87b50
commit 29fce8361f

@ -2,9 +2,9 @@
{{ $copyright := site.Copyright }} {{ $copyright := site.Copyright }}
{{ $description := or $page.Description "Recent content" }} {{ $description := or $page.Description "Recent content" }}
{{ $format := "Mon, 02 Jan 2006 15:04:05 MST" }}
{{ $guids := dict }} {{ $guids := dict }}
{{ $html := $page.AlternativeOutputFormats.Get "html" }} {{ $html := $page.AlternativeOutputFormats.Get "html" }}
{{ $lastbuilddate := (partial "paige/changed.html" $page).Format "Mon, 02 Jan 2006 15:04:05 MST" }}
{{ $language := site.LanguageCode | default site.Language.Lang }} {{ $language := site.LanguageCode | default site.Language.Lang }}
{{ $limit := site.Config.Services.RSS.Limit }} {{ $limit := site.Config.Services.RSS.Limit }}
{{ $link := $page.Permalink }} {{ $link := $page.Permalink }}
@ -15,6 +15,8 @@
{{ $title := "" }} {{ $title := "" }}
{{ $webmaster := $page.Param "paige.feed.rss.web_master" }} {{ $webmaster := $page.Param "paige.feed.rss.web_master" }}
{{ $lastbuilddate := (partial "paige/changed.html" $page).Format $format }}
{{ if and $pagetitle $sitetitle }} {{ if and $pagetitle $sitetitle }}
{{ if $page.IsHome }} {{ if $page.IsHome }}
{{ $title = $pagetitle }} {{ $title = $pagetitle }}
@ -70,7 +72,7 @@
{{ $guid := "" }} {{ $guid := "" }}
{{ $paramlink := and .Params.link (not (.Param "paige.feed.link_to_page")) | not | not }} {{ $paramlink := and .Params.link (not (.Param "paige.feed.link_to_page")) | not | not }}
{{ $permalink := false }} {{ $permalink := false }}
{{ $pubdate := .PublishDate.Format "Mon, 02 Jan 2006 15:04:05 MST" }} {{ $pubdate := .PublishDate.Format $format }}
{{ $title := .Title | markdownify | plainify }} {{ $title := .Title | markdownify | plainify }}
{{ $link := cond $paramlink .Params.link .Permalink }} {{ $link := cond $paramlink .Params.link .Permalink }}

Loading…
Cancel
Save