jk.nipponalba.scot website
https://jk.nipponalba.scot
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
92 lines
4.5 KiB
92 lines
4.5 KiB
{{ printf `<?xml version="1.0" encoding="utf-8"?>` | safeHTML }} {{/* ref: https://validator.w3.org/feed/docs/atom.html */}}
|
|
<feed xmlns="http://www.w3.org/2005/Atom"{{ with site.LanguageCode }} xml:lang="{{ . }}"{{ end }}>
|
|
<generator uri="https://gohugo.io/" version="{{ hugo.Version }}">Hugo</generator>
|
|
<link href="http://pubsubhubbub.superfeedr.com/" rel="hub"/>
|
|
{{- $title := site.Title -}}
|
|
{{- with .Title -}}
|
|
{{- if (not (eq . site.Title)) -}}
|
|
{{- $title = printf `%s %s %s` . (i18n "feed_title_on" | default "on") site.Title -}}
|
|
{{- end -}}
|
|
{{- end -}}
|
|
{{ printf `<title type="html"><![CDATA[%s]]></title>` $title | safeHTML }}
|
|
{{ with (or (.Param "subtitle") (.Param "tagline")) }}
|
|
{{ printf `<subtitle type="html"><![CDATA[%s]]></subtitle>` . | safeHTML }}
|
|
{{ end }}
|
|
{{ $output_formats := .OutputFormats }}
|
|
{{ range $output_formats -}}
|
|
{{- $rel := (or (and (eq "atom" (.Name | lower)) "self") "alternate") -}}
|
|
{{ with $output_formats.Get .Name }}
|
|
{{ printf `<link href=%q rel=%q type=%q title=%q />` .Permalink $rel .MediaType.Type .Name | safeHTML }}
|
|
{{- end -}}
|
|
{{- end }}
|
|
<updated>{{ now.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</updated>
|
|
{{ with site.Copyright }}
|
|
{{- $copyright := replace . "{year}" now.Year -}} {{/* In case the site.copyright uses a special string "{year}" */}}
|
|
{{- $copyright = replace $copyright "©" "©" -}}
|
|
<rights>{{ $copyright | plainify }}</rights>
|
|
{{- end }}
|
|
{{ with .Param "feed" }}
|
|
{{/* For this to work, the $icon file should be present in the assets/ directory */}}
|
|
{{- $icon := .icon | default "icon.svg" -}}
|
|
{{- with resources.Get $icon -}}
|
|
<icon>{{ (. | fingerprint).Permalink }}</icon>
|
|
{{- end }}
|
|
|
|
{{/* For this to work, the $logo file should be present in the assets/ directory */}}
|
|
{{- $logo := .logo | default "logo.svg" -}}
|
|
{{- with resources.Get $logo -}}
|
|
<logo>{{ (. | fingerprint).Permalink }}</logo>
|
|
{{- end }}
|
|
{{ end }}
|
|
{{ with site.Author.name -}}
|
|
<author>
|
|
<name>{{ . }}</name>
|
|
{{ with site.Author.email }}
|
|
<email>{{ . }}</email>
|
|
{{ end -}}
|
|
</author>
|
|
{{- end }}
|
|
{{ with site.Params.id }}
|
|
<id>{{ . | plainify }}</id>
|
|
{{ else }}
|
|
<id>{{ .Permalink }}</id>
|
|
{{ end }}
|
|
{{- $limit := (cond (le site.Config.Services.RSS.Limit 0) 65536 site.Config.Services.RSS.Limit) }}
|
|
{{- $feed_sections := site.Params.feedSections | default site.Params.mainSections -}}
|
|
{{/* Range through only the pages with a Type in $feed_sections. */}}
|
|
{{- $pages := where .RegularPages "Type" "in" $feed_sections -}}
|
|
{{- if (eq .Kind "home") -}}
|
|
{{- $pages = where site.RegularPages "Type" "in" $feed_sections -}}
|
|
{{- end -}}
|
|
{{/* Remove the pages that have the disable_feed parameter set to true. */}}
|
|
{{- $pages = where $pages ".Params.disable_feed" "!=" true -}}
|
|
{{- range first $limit $pages }}
|
|
{{ $page := . }}
|
|
<entry>
|
|
{{ printf `<title type="html"><![CDATA[%s]]></title>` .Title | safeHTML }}
|
|
<link href="{{ .Permalink }}?utm_source=atom_feed" rel="alternate" type="text/html" />
|
|
{{- range .Translations }}
|
|
{{- $link := printf "%s?utm_source=atom_feed" .Permalink | safeHTML }}
|
|
{{- printf `<link href=%q rel="alternate" type="text/html" hreflang=%q />` $link .Lang | safeHTML }}
|
|
{{- end }}
|
|
{{ with .Params.id }}
|
|
<id>{{ . | plainify }}</id>
|
|
{{ else }}
|
|
<id>{{ .Permalink }}</id>
|
|
{{ end }}
|
|
{{ with .Params.author -}}
|
|
{{- range . -}} <!-- Assuming the author front-matter to be a list -->
|
|
<author>
|
|
<name>{{ . }}</name>
|
|
</author>
|
|
{{- end -}}
|
|
{{- end }}
|
|
<published>{{ .Date.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</published>
|
|
<updated>{{ .Lastmod.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</updated>
|
|
{{ $description1 := .Description | default "" }}
|
|
{{ $description := (cond (eq "" $description1) "" (printf "<blockquote>%s</blockquote>" ($description1 | markdownify))) }}
|
|
{{ printf `<content type="html"><![CDATA[%s%s]]></content>` $description .Content | safeHTML }}
|
|
|
|
</entry>
|
|
{{ end }}
|
|
</feed>
|