mirror of
https://github.com/by-jp/www.byjp.me.git
synced 2025-08-09 22:16:07 +01:00
Add context about events in RSS feed
This commit is contained in:
parent
d4a9346577
commit
6cf051f69a
1 changed files with 11 additions and 9 deletions
|
@ -24,7 +24,8 @@
|
|||
{{- with .OutputFormats.Get "RSS" -}}
|
||||
{{ printf "<atom:link href=%q rel=\"self\" type=%q />" (.Permalink | absURL) .MediaType | safeHTML }}
|
||||
{{- end -}}
|
||||
{{ range $i, $page := $pages }}
|
||||
{{- range $i, $page := $pages -}}
|
||||
{{- if .params.inReplyTo -}}{{ continue }}{{- end -}}
|
||||
<item>
|
||||
<title>{{ .Title | default (delimit (slice "An untitled" (.Date.Format "January") (.Type | singularize)) " ") }}</title>
|
||||
<link>{{ .Permalink | absURL }}</link>
|
||||
|
@ -32,12 +33,13 @@
|
|||
<pubDate>{{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}</pubDate>
|
||||
<guid>{{ .Permalink | absURL }}</guid>
|
||||
<description>
|
||||
{{ if .Params.bookmarkOf }}
|
||||
{{- if .Params.bookmarkOf -}}
|
||||
{{- $reference := partial "reference.obj" (dict "url" .Params.bookmarkOf "page" .) -}}
|
||||
Thoughts on a bookmarked article{{ with $reference.name }}: {{.}}{{ end }}.
|
||||
{{ else }}
|
||||
{{ index (split .Summary "\n") 0 }}
|
||||
{{ end }}
|
||||
{{- else -}}
|
||||
{{- if eq .Section "calendar" -}}(An event I may be going to.) {{ end -}}
|
||||
{{- index (split .Summary "\n") 0 -}}
|
||||
{{- end -}}
|
||||
</description>
|
||||
<content:encoded>
|
||||
{{- range $i, $src := .Params.Media }}
|
||||
|
@ -52,15 +54,15 @@
|
|||
{{ end -}}
|
||||
{{ end -}}
|
||||
{{ if $timing }}
|
||||
<p style="font-style:italic;font-size:small">I'm planning on going to this event on
|
||||
<p><i><small>I'm planning on going to this event on
|
||||
{{ partial "year-relative-date.txt" (time.AsTime $timing.starts) }}.
|
||||
See the bottom of <a href="{{ .Permalink | absURL }}#post-info">the post</a> for more information, and get in touch if you'd like to go together!</p>
|
||||
See the bottom of <a href="{{ .Permalink | absURL }}#post-info">the post</a> for more information, and get in touch if you'd like to go together!</small></i></p>
|
||||
{{ end }}
|
||||
{{- end -}}
|
||||
{{ if .Params.bookmarkOf }}
|
||||
<p><i>{{ partial "bookmark-of.html" . | html }}</i></p>
|
||||
<p><i><small>{{ partial "bookmark-of.html" . | html }}</small></i></p>
|
||||
{{ else if .Params.inReplyTo }}
|
||||
<p><i>{{ partial "in-reply-to.html" . | html }}</i></p>
|
||||
<p><i><small>{{ partial "in-reply-to.html" . | html }}</small></i></p>
|
||||
{{ end }}
|
||||
{{ .Content | html }}
|
||||
</content:encoded>
|
||||
|
|
Loading…
Reference in a new issue