Separate post tags with commas
authorJavier Sancho <jsf@jsancho.org>
Mon, 26 Feb 2018 16:00:59 +0000 (17:00 +0100)
committerJavier Sancho <jsf@jsancho.org>
Mon, 26 Feb 2018 16:00:59 +0000 (17:00 +0100)
haunt.scm

index 96838c4..7ad26ee 100644 (file)
--- a/haunt.scm
+++ b/haunt.scm
                   `(" "
                     (span (@ (style "margin: 0 3px")) ÔŽ┐)
                     (span (@ (class "tags"))
-                          ,@(map (lambda (tag)
-                                   `((a (@ (href ,(format #f "tags/~a.html" tag))) ,tag) " "))
-                                 tags)))))
+                          ,@(drop-right
+                              (apply
+                               append
+                               (map (lambda (tag)
+                                      `((a (@ (href ,(format #f "tags/~a.html" tag))) ,tag) ", "))
+                                    tags))
+                              1)))))
          (else
           div))))