X-Git-Url: https://git.shemshak.org/gitweb.cgi/~bandali/bndl.org/blobdiff_plain/99ac860dcc0e325fe949bbc8ad8db008e0c4d24c..9016913936fd2340a11483e90eb2b75746b47b79:/haunt.scm diff --git a/haunt.scm b/haunt.scm index 49db025..7be77b3 100644 --- a/haunt.scm +++ b/haunt.scm @@ -33,7 +33,9 @@ (a (@ (href "license.html")) "license.html") " for license conditions. Please copy and share.")))))) -(define (bandali-post-template post) +(define my-date-format "~B ~d, ~Y") + +(define (my-post-template post) `((header (h1 ,(post-ref post 'title)) (address "By " @@ -41,10 +43,23 @@ ,(post-ref post 'author)) " <" ,(post-ref post 'email) ">") (p (@ (class "date")) - ,(date->string (post-date post) "~B ~d, ~Y"))) - ,(post-sxml post))) + ,(date->string (post-date post) my-date-format))) + ,(post-sxml post) + (p (@ (class "muted inbox")) + "Have a question or comment? Start a discussion in my " + (a (@ (href "https://lists.sr.ht/~bandali/public-inbox")) + "public inbox") + " by sending an email to " + (a (@ (href "mailto:~bandali/public-inbox@lists.sr.ht")) + "~bandali/public-inbox@lists.sr.ht") + (small + " [" + (a (@ (href "https://man.sr.ht/lists.sr.ht/etiquette.md")) + "mailing list etiquette") + "]") + "."))) -(define (bandali-collection-template site title posts prefix) +(define (my-collection-template site title posts prefix) (define (post-uri post) (string-append (or prefix "") "/" (site-post-slug site post) ".html")) @@ -55,7 +70,7 @@ `(li (a (@ (href ,(post-uri post))) ,(post-ref post 'title)) - " — " ,(date->string (post-date post) "~B ~d, ~Y"))) + " — " ,(date->string (post-date post) my-date-format))) posts)))) (define bandali-theme @@ -64,8 +79,14 @@ (lambda (site title body) (base-layout site body #:title title)) - #:post-template bandali-post-template - #:collection-template bandali-collection-template)) + #:post-template my-post-template + #:collection-template my-collection-template)) + +(define (static-page title file-name body) + (lambda (site posts) + (make-page file-name + (with-layout bandali-theme site title body) + sxml->html))) (define (index-material site posts) `(div @@ -137,14 +158,12 @@ (dl (dt "A Comparison of the Declarative Modelling Languages B, DASH, and TLA" (sup "+") - (span (@ (class "plinks")) - " [ " - (a (@ (href "papers/modre2018-declarative.pdf")) - "pdf") - " | " - (a (@ (href "papers/modre2018-declarative.bib")) - "bib") - " ]")) + (small + " [ " + (a (@ (href "papers/modre2018-declarative.pdf")) "pdf") + " | " + (a (@ (href "papers/modre2018-declarative.bib")) "bib") + " ]")) (dd "Ali Abbassi, " (a (@ (href "https://bandali.eu.org")) "Amin Bandali") ", " (a (@ (href "https://cs.uwaterloo.ca/~nday/")) @@ -213,7 +232,7 @@ (td (a (@ (href ,(post-uri post))) ,(post-ref post 'title))) (td (@ (style "font-size: 0.875em;")) - ,(date->string (post-date post) "~B ~d, ~Y")))) + ,(date->string (post-date post) my-date-format)))) (take-up-to 10 (posts/reverse-chronological posts))))))) (define (index-page site posts) @@ -222,6 +241,32 @@ (base-layout site (index-material site posts)) sxml->html)) +(define license-page + (static-page + "Licensing Information" + "license.html" + `((h1 "License information for bandali.eu.org") + (p "I strongly believe in " + (a (@ (href "https://questioncopyright.org/what_is_free_culture")) + "free culture") + " and that all creative works everywhere should be " + (a (@ (href "https://freedomdefined.org/Definition")) "free" + ".")) + (p "Unless otherwise noted material on this site is licensed " + "under the GNU General Public License as published by the " + "Free Software Foundation, either version 3 of the License, " + "or (at your option) any later version. A copy of the " + "license is included at " + (a (@ (href "gpl-3.0.html")) "gpl-3.0.html") ".") + (p "Some resources on free software and licenses:") + (ul + (li (a (@ (href "https://www.gnu.org/philosophy/free-sw.html")) + "What is free software?")) + (li (a (@ (href "https://www.gnu.org/licenses/license-list.html")) + "Various Licenses and Comments about Them")) + (li (a (@ (href "https://www.gnu.org/proprietary/proprietary.html")) + "Proprietary Software Is Often Malware")))))) + (define my-domain "bandali.eu.org") (site #:title "Amin Bandali" @@ -242,4 +287,5 @@ #:prefix "tags") (rss-feed #:file-name "feed.rss") + license-page (static-directory "static" "")))