diff --git a/README.md b/README.md index ff27b4c..fbef84a 100644 --- a/README.md +++ b/README.md @@ -21,8 +21,13 @@ css](https://simplecss.org) and sometimes [seirdy's site](https://seirdy.one). ## todo - [ ] let gemini version also have a post page at /posts/index.gmi -- [ ] post-index.md and gmi for content put after the posts list -- [ ] rethink on the post slugs. currently `/posts/file-name-or-slug/` but I - might put the date or something in there idk - - [ ] minify images and use WebP +- [x] provide atom feed for www +- [x] show post description in list + +- [ ] content improvements + - [ ] about + - [ ] projects + - [ ] syntax hilite post + - [ ] gemini post +- [ ] proper reply via email link diff --git a/config.toml b/config.toml index def57c1..1bd2fe6 100644 --- a/config.toml +++ b/config.toml @@ -94,8 +94,15 @@ isHTML = false noUgly = false permalinkable = false +# https://gist.github.com/lpar/7ded35d8f52fef7490a5be92e6cd6937 +[outputFormats.ATOM] +name = "ATOM" +mediaType = "application/atom" +baseName = "atom" +isPlainText = false + [outputs] -section = ["HTML", "RSS", "GEMATOM"] +section = ["HTML", "RSS", "GEMATOM", "ATOM"] [webmentions] newDir = "public" diff --git a/content/posts/2021-02-05-hello.md b/content/posts/2021-02-05-hello.md index ad9f2c9..c2610ba 100644 --- a/content/posts/2021-02-05-hello.md +++ b/content/posts/2021-02-05-hello.md @@ -2,6 +2,7 @@ title: "Hello" date: 2021-02-05T01:44:15Z draft: false +description: "I'm alive!" tags: - test outputs: diff --git a/content/posts/2021-06-15-on-rants-gemini.md b/content/posts/2021-06-15-on-rants-gemini.md index 54f471f..40dba3d 100644 --- a/content/posts/2021-06-15-on-rants-gemini.md +++ b/content/posts/2021-06-15-on-rants-gemini.md @@ -8,7 +8,7 @@ outputs: - html - gemtext slug: "on-rants-gemini" -description: "A Discussion about some of the complaints of the Gemini Protocol recently" +description: "A discussion about Gemini and addressing some of the complaints of the Gemini Protocol seen on the internet recently." --- diff --git a/content/posts/2021-06-16-multiple-emails-git.md b/content/posts/2021-06-16-multiple-emails-git.md index a0f89b9..9050fe5 100644 --- a/content/posts/2021-06-16-multiple-emails-git.md +++ b/content/posts/2021-06-16-multiple-emails-git.md @@ -10,7 +10,7 @@ date: 2021-06-16T23:50:00Z draft: false slug: "multiple-emails-git" highlight: true -description: "How to have different git configs depending on the computer and have it tracked with dotfiles" +description: "How to have different git author configurations depending on the computer and have it tracked with dotfiles." --- diff --git a/content/posts/2021-06-20-another-test.md b/content/posts/2021-06-20-another-test.md index 7c6fcb7..86ca384 100644 --- a/content/posts/2021-06-20-another-test.md +++ b/content/posts/2021-06-20-another-test.md @@ -1,7 +1,7 @@ --- title: "Another Test" date: 2021-06-20T21:33:27+08:00 -draft: false +draft: true outputs: - html - gemtext diff --git a/content/posts/2021-08-05-hugo-syntax-highlighting.md b/content/posts/2021-08-05-hugo-syntax-highlighting.md index 4050d1d..1804504 100644 --- a/content/posts/2021-08-05-hugo-syntax-highlighting.md +++ b/content/posts/2021-08-05-hugo-syntax-highlighting.md @@ -9,7 +9,7 @@ outputs: slug: hugo-syntax-highlighting tags: - howto -description: "How I've set up syntax highlighting for hugo, powered by chroma." +description: "How I've set up syntax highlighting for my website with dark mode support." --- diff --git a/layouts/_default/section.atom.xml b/layouts/_default/section.atom.xml new file mode 100644 index 0000000..617961f --- /dev/null +++ b/layouts/_default/section.atom.xml @@ -0,0 +1,33 @@ +{{- $pctx := . -}} +{{- if .IsHome -}}{{ $pctx = .Site }}{{- end -}} +{{- $pages := slice -}} +{{- if or $.IsHome $.IsSection -}} +{{- $pages = $pctx.RegularPages -}} +{{- else -}} +{{- $pages = $pctx.Pages -}} +{{- end -}} +{{- printf "" | safeHTML }} + + hedy's blog + + {{ .Date.Format "2006-01-02" | safeHTML }}T12:00:00Z + {{ .Permalink }} + + {{ $.Site.Author.name }} + {{ $.Site.Author.email }} + + {{- range where .Site.Pages "Kind" "page" }} + {{- if or (eq .Section "posts") (eq .Section "post") }} + + {{ .Title }} + {{ printf `` .Permalink | safeHTML }} + {{ .Permalink }} + {{ .Date.Format "2006-01-02" }}T12:00:00Z + + {{ $.Site.Author.name }} + {{ $.Site.Author.email }} + + + {{- end }} + {{- end }} + diff --git a/layouts/_default/section.gematom.xml b/layouts/_default/section.gematom.xml index 95a60a9..5c3a314 100644 --- a/layouts/_default/section.gematom.xml +++ b/layouts/_default/section.gematom.xml @@ -12,13 +12,13 @@ {{ .Date.Format "2006-01-02" | safeHTML }}T12:00:00Z {{ .Site.Params.geminiRoot }} - {{- range (where .Site.RegularPages "Section" "posts") -}} - {{- $p := . -}} - {{- with .OutputFormats.Get "gemtext" }} {{ $.Site.Author.name }} {{ $.Site.Author.email }} + {{- range (where .Site.RegularPages "Section" "posts") -}} + {{- $p := . -}} + {{- with .OutputFormats.Get "gemtext" }} {{- $perm := replace (replace .Permalink "/gemini" "" 1) "/index.gmi" ".gmi" 1 }} {{ $p.Title }} diff --git a/layouts/partials/posts.html b/layouts/partials/posts.html index d7c2e80..2c12f22 100644 --- a/layouts/partials/posts.html +++ b/layouts/partials/posts.html @@ -1,20 +1,36 @@ -{{ $outerRel := .RelPermalink }} +{{ $outerRel := .RelPermalink -}} {{ if in $outerRel "posts" -}}

Posts

{{ else -}}

Posts

{{ end -}} -

All tags | RSS feed

-