diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 80964f2..4862711 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -17,21 +17,20 @@ {{ if .Data.Singular }} diff --git a/layouts/_default/single.gmi b/layouts/_default/single.gmi new file mode 100644 index 0000000..24ac0e6 --- /dev/null +++ b/layouts/_default/single.gmi @@ -0,0 +1,19 @@ +# {{ $.Title | safeHTML }} + +{{ trim (readFile (replace $.File.Path ".md" ".gmi")) "\n" | safeHTML }} + +```ASCII + . + ,O, + ,OOO, + 'oooooOOOOOooooo' + `OOOOOOOOOOO` + `OOOOOOO` + OOOO'OOOO + OOO' 'OOO + O' 'O +``` + +=> / Return to the homepage + +{{ .Site.Copyright }} diff --git a/layouts/blog/single.gmi b/layouts/blog/single.gmi new file mode 100644 index 0000000..ae72845 --- /dev/null +++ b/layouts/blog/single.gmi @@ -0,0 +1,30 @@ +# {{ $.Title | safeHTML }} + +{{ if .Lastmod }}{{ if not (eq .Lastmod .Date )}} +Published on {{ .Date.Format "Jan 02, 2006" }}, updated {{ dateFormat "2006-01-02" .Lastmod.Local }}. +{{ end }} +{{ else }} +Published on {{ .Date.Format "Jan 02, 2006" }}. +{{ end }} + +{{ trim (readFile (replace $.File.Path ".md" ".gmi")) "\n" | safeHTML }} + +```ASCII + * . * . , * + . . . * + * . .' * , . . , * + . * .' + ' . . * * .'. + . ' ' . . ' . +. * , * ' * + . + * . * +``` + +=> / Return to the homepage +{{ with .OutputFormats.Get "html" }} +=> {{ .Permalink }} See “{{ $.Title | safeHTML }}” on the WWW +{{ end }} +{{ with .Params.comments }}=> https://{{ .host }}/@{{ .user }}/{{ .id }} You may comment here{{ end }} + +{{ .Site.Copyright }} diff --git a/layouts/blog/single.html b/layouts/blog/single.html index 7135707..542ca44 100644 --- a/layouts/blog/single.html +++ b/layouts/blog/single.html @@ -1,21 +1,23 @@ {{ define "main" }}

{{ .Title }}

-

- • Published on -

{{ .Content }} diff --git a/layouts/index.gmi b/layouts/index.gmi new file mode 100644 index 0000000..d8476f8 --- /dev/null +++ b/layouts/index.gmi @@ -0,0 +1,14 @@ +{{ trim (readFile (replace (replace $.File.Path ".md" ".gmi") ".html" ".gmi")) "\n" | safeHTML }} + +## Blog Posts + +{{ with .OutputFormats.Get "html" }} +=> {{ .Permalink }} More posts on WWW +{{ end }} + +{{ range (where .Site.RegularPages "Section" "blog") }} +{{- if .OutputFormats.Get "gemtext" }} +=> {{ replace .Permalink "/gemini" "" 1 }} {{ .Date.Format "Jan 02, 2006" }}: {{ .Title | safeHTML }}{{ end }}{{ end }} + + +{{ .Site.Copyright }}