1
mirror of https://github.com/jakejarvis/jarv.is.git synced 2025-04-27 05:18:28 -04:00
jarv.is/layouts/index.atom
Jake Jarvis 363b4edf1c
shift asset processing to webpack (#424)
also migrated SASS to latest syntax (via dart-sass) and vastly simplified light/dark theme logic
2021-06-19 17:19:01 -04:00

42 lines
1.6 KiB
XML

{{- $img := partial "functions/init" . -}}
{{ printf "<?xml version=\"1.0\" encoding=\"utf-8\"?>" | safeHTML }}
<feed xmlns="http://www.w3.org/2005/Atom">
<title>{{ .Site.Title }}</title>
<id>{{ print .Site.Params.baseUrl .Permalink }}</id>
<author>
<name>{{ .Site.Title }}</name>
<uri>{{ print .Site.Params.baseUrl .Permalink }}</uri>
</author>
<generator>Hugo -- gohugo.io</generator>
{{- with .Site.Copyright }}
<rights>{{ . }}</rights>
{{- end }}
{{- with .Scratch.Get "authorImage" }}
<logo>{{ print $.Site.Params.baseUrl .Permalink }}</logo>
{{- end }}
<updated>{{ .Site.LastChange.Format "2006-01-02T15:04:05Z" | safeHTML }}</updated>
{{- with .OutputFormats.Get "ATOM" }}
{{ printf `<link rel="self" type="%s" href="%s" />` .MediaType.Type (print $.Site.Params.baseUrl .Permalink) | safeHTML }}
{{- end }}
{{- range .AlternativeOutputFormats }}
{{ printf `<link rel="alternate" type="%s" href="%s" />` .MediaType.Type (print $.Site.Params.baseUrl .Permalink) | safeHTML }}
{{- end }}
{{- range (where .Site.RegularPages "Section" .Site.Params.mainSection) }}
<entry>
<title>{{ .Title | markdownify | htmlUnescape | plainify }}</title>
{{- with .Site.Author.name }}
<author>
<name>{{ . }}</name>
<uri>{{ print $.Site.Params.baseUrl $.Permalink }}</uri>
</author>
{{- end }}
<id>{{ print $.Site.Params.baseUrl .Permalink }}</id>
<published>{{ .Date.UTC.Format "2006-01-02T15:04:05Z" | safeHTML }}</published>
<updated>{{ .Date.UTC.Format "2006-01-02T15:04:05Z" | safeHTML }}</updated>
<content type="html">
{{ .Content | html }}
</content>
</entry>
{{- end }}
</feed>