diff options
| author | Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> | 2024-03-19 18:46:16 +0100 |
|---|---|---|
| committer | Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> | 2025-06-15 01:30:27 +0200 |
| commit | 9a9ec1f61251e7c31f7b768a815fb3afcf8773f3 (patch) | |
| tree | 411668e18540b821d01e09e9fe963277e857c892 /website/builders/replicant-blog.scm | |
| parent | 325ffa517ad063e25368205ed45c48ec4d6a5cc8 (diff) | |
| download | haunt-blog-9a9ec1f61251e7c31f7b768a815fb3afcf8773f3.tar.gz haunt-blog-9a9ec1f61251e7c31f7b768a815fb3afcf8773f3.tar.bz2 haunt-blog-9a9ec1f61251e7c31f7b768a815fb3afcf8773f3.zip | |
haunt: Add metadata in the articles.
Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org>
Diffstat (limited to 'website/builders/replicant-blog.scm')
| -rw-r--r-- | website/builders/replicant-blog.scm | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/website/builders/replicant-blog.scm b/website/builders/replicant-blog.scm index 92c2475..1f8052b 100644 --- a/website/builders/replicant-blog.scm +++ b/website/builders/replicant-blog.scm @@ -73,6 +73,25 @@ (define (replicant-default-post-template post) `((h1 (@ (id "title")) ,(post-ref post 'title)) + ;; Metadata + (p (string-append + "Posted" + ,(if + (post-ref post 'authors) + (string-append " by " (post-ref post 'authors)) + "") + ,(if + (post-ref post 'date) + (string-append + " on the " + (date->string (post-ref post 'date) "~d ~B ~Y at ~kh~M")) + "") + ,(if (post-ref post 'licenses) + (string-append + " under the " + (post-ref post 'licenses) " license(s)") + "") + ".")) (div (@ (id "post-content")) ,(post-sxml post)))) (define (replicant-default-collection-template site title posts prefix) |
