diff options
Diffstat (limited to 'website/builders/replicant-blog.scm')
| -rw-r--r-- | website/builders/replicant-blog.scm | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/website/builders/replicant-blog.scm b/website/builders/replicant-blog.scm index 1f8052b..918bc5b 100644 --- a/website/builders/replicant-blog.scm +++ b/website/builders/replicant-blog.scm @@ -94,6 +94,11 @@ ".")) (div (@ (id "post-content")) ,(post-sxml post)))) +(define (sort-posts-by-most-recent-first a b) + (time>? + (date->time-utc (post-ref a 'date)) + (date->time-utc (post-ref b 'date)))) + (define (replicant-default-collection-template site title posts prefix) (define (post-uri post) (string-append (or prefix "") "/" @@ -105,7 +110,7 @@ `(li (a (@ (href ,(post-uri post))) ,(post-ref post 'title)))) - posts)))) + (sort posts sort-posts-by-most-recent-first))))) (define* (theme #:key (name "Replicant") |
