Compare commits

...

3 Commits

Author SHA1 Message Date
hedy 51c2835821
Fix link in README 2024-04-17 15:06:04 +08:00
hedy a6c3079a16
Update gemini general page format 2024-04-15 21:40:37 +08:00
hedy 0b26a6b51b
Update gemini post format 2024-04-15 09:12:44 +08:00
4 changed files with 13 additions and 14 deletions

View File

@ -1,7 +1,7 @@
# ~hedy's site
This is my website and gemini capsule source code. Link is currently
hedy.tilde.cafe on both [web](https://home.hedy.dev) and
home.hedy.dev on both [web](https://home.hedy.dev) and
[gemini](gemini://home.hedy.dev).
As of now, static site hosting is provided by srht.site.

View File

@ -2,13 +2,10 @@
# {{ .Title }}
{{ $lastmod := .Lastmod -}}
{{ if lt .Date $lastmod -}}
Last updated {{ .Lastmod.UTC.Format "2006-01-02" }}{{ end }}
--
{{ trim (readFile (replace $.File.Path ".md" ".gmi")) "\n" | safeHTML }}
{{ partial "processed-content.gmi" . }}
--
{{ partial "lastmod.gmi" (dict "Page" . "Prefix" "Last updated on " "Postfix" "." ) }}
=> / Home
{{- end }}

View File

@ -1,2 +1 @@
{{ $lastmod := .Page.Lastmod -}}
{{- if lt .Page.Date $lastmod }}{{ with .Prefix }}{{ . }}{{ end }}Last updated on {{ $lastmod.Format "Jan 02, 2006" }}{{ with .Postfix }}{{ . }}{{ end }}{{ end -}}
{{ $lastmod := .Page.Lastmod -}}{{ if lt .Page.Date $lastmod }}{{ with .Prefix }}{{ . }}{{ end }}{{ $lastmod.Format "Jan 02, 2006" }}{{ with .Postfix }}{{ . }}{{ end }}{{ end -}}

View File

@ -1,17 +1,20 @@
{{ define "content" -}}
# {{ $.Title }}
{{ .Date.UTC.Format "Jan 02, 2006" }} · {{ .WordCount }} words
{{ partial "lastmod.gmi" (dict "Page" . "Postfix" ".") }}
--
{{ .Date.UTC.Format "Jan 02, 2006" }}
{{ partial "processed-content.gmi" . }}
--
***
EOF
{{ $subject := urlquery (printf "Re: %s" .Title) }}
=> {{ with .Params.publicReplyTo }}{{ . |safeHTML }}{{ else }}mailto:~hedy/posts@lists.sr.ht?subject={{ $subject }}{{ end }} Reply via email publicly (plain-text only)
=> mailto:{{ .Site.Author.email }}?subject={{ $subject }} Reply via email privately
{{ .WordCount }} words
{{ partial "lastmod.gmi" (dict "Page" . "Prefix" "This post was last updated on " "Postfix" ".") }}
=> / Home
=> . ← Gemlog
=> / ← Capsule home
{{- end }}