{{- $items := slice -}} {{- range where site.RegularPages "Section" "notes" -}} {{- if not .Params.updated -}} {{- errorf "Missing required updated date in %s" .File.Path -}} {{- end -}} {{- $sortKey := printf "%s|%s" (.Lastmod.Format "2006-01-02T15:04:05-0700") .RelPermalink -}} {{- $items = $items | append (dict "page" . "sortKey" $sortKey) -}} {{- end -}} {{- $items = sort $items "sortKey" "desc" -}} {{ printf "" | safeHTML }} {{ site.Params.owner }} — Notes Updates {{ .Permalink }} New and substantially revised technical notes by {{ site.Params.owner }}. {{- with $items }} {{ (index . 0).page.Lastmod.Format "Mon, 02 Jan 2006 15:04:05 -0700" }} {{- end }} {{- range $items }} {{- $page := .page -}} {{- $title := $page.Title -}} {{- if $page.Params.series -}} {{- $title = printf "%s — %s" $page.Parent.Title $page.Title -}} {{- end -}} {{- $summary := $page.Plain | strings.Truncate 200 -}} {{- with $page.Params.description -}} {{- $summary = . | plainify -}} {{- end -}} {{ $title }} {{ $page.Permalink }} {{ printf "%s#updated-%s" $page.Permalink ($page.Lastmod.Format "2006-01-02") }} {{ $page.Lastmod.Format "Mon, 02 Jan 2006 15:04:05 -0700" }} {{ $summary }} {{- end }}