{{ define "main" }}

{{ .Title }}

{{- $pub := .Date.Format "Jan 2, 2006" -}} {{- $mod := "" -}} {{- if (not .GitInfo) }} {{- $mod = .Lastmod.Format "Jan 2, 2006" -}} {{ else }} {{- $mod = .Page.GitInfo.CommitDate.Format "Jan 2, 2006" -}} {{ end -}} {{ if eq $pub $mod }}
published {{ $pub }}
{{ else }}
published {{ $pub }} - last modified {{ $mod }}
{{ end }} {{ if .Params.tags }}
{{ if eq (len .Params.tags) 1 }} tag: {{ else }} tags: {{ end }} {{ range $idx, $tag := .Params.tags }} {{ $tag }} {{ end }}
{{ end }}
{{ if .Params.toc }}
Table of contents {{ .TableOfContents }}
{{ end }}
{{ .Content }}
{{ if .Params.toc }}
Table of contents {{ .TableOfContents }}
{{ end }} {{ end }}