From a6ac6b919970ab9e4b04f9c3cc1640c12b4015fe Mon Sep 17 00:00:00 2001 From: Jakob L. Kreuze Date: Fri, 17 May 2019 11:56:24 -0400 Subject: Refactor SXML --- haunt/projects.scm | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) (limited to 'haunt/projects.scm') diff --git a/haunt/projects.scm b/haunt/projects.scm index 5951913..ec188e6 100644 --- a/haunt/projects.scm +++ b/haunt/projects.scm @@ -14,6 +14,8 @@ ;;; along with this program. If not, see ;;; . +(use-modules (custom sxml)) + (define %software-projects '(("Brisket" "Active" "https://git.sr.ht/~jakob/brisket" @@ -44,27 +46,26 @@ ("Experimental FluidSynth MIDI driver for EDuke32.")))) (define %software-contributions - '(("Haiku" "Finished" + `(("Haiku" "Finished" "https://www.haiku-os.org/" ("The Haiku operating system." - (ul (li (a (@ (href "https://git.haiku-os.org/haiku/commit/?id=354e11bf3cd4a94129df894eea3b34ac6241bbb5")) - " 354e11b: Add mime_db entry for application/vnd.apple.mpegurl (M3U)")) - (li (a (@ (href "https://git.haiku-os.org/haiku/commit/?id=0f856497bd2dd397024df14997f1bed4a514de04")) - "0f85649: mediaplayer: Implement AppendM3uToPlaylist"))))))) + (ul (li ,(link "354e11b: Add mime_db entry for application/vnd.apple.mpegurl (M3U)" + "https://git.haiku-os.org/haiku/commit/?id=354e11bf3cd4a94129df894eea3b34ac6241bbb5")) + (li ,(link "0f85649: mediaplayer: Implement AppendM3uToPlaylist" + "https://git.haiku-os.org/haiku/commit/?id=0f856497bd2dd397024df14997f1bed4a514de04"))))))) (define %packaging-projects '(("zerodaysfordays" "Active" "https://git.sr.ht/~jakob/zerodaysfordays" ("My personal Gentoo ebuild overlay.")))) -(define (project name status link description) +(define (project name status url description) (let ((status-class (cond ((string= status "Active") "info") ((string= status "Finished") "good") ((string= status "Dormant") "okay") ((string= status "Abandoned") "bad") (else "info")))) - (display status-class) - `(tr (td (a (@ (href ,link)) ,name)) + `(tr (td ,(link name url)) (td (span (@ (class ,(string-append "label " status-class))) ,status)) (td ,@description)))) @@ -78,4 +79,4 @@ (p "I'm still in the process of putting things together, so this page is a bit empty.") ,@(project-section "Software I Maintain" %software-projects) ,@(project-section "Packaging" %packaging-projects) - ,@(project-section "Software I've Contributed To" %software-contributions)) + ,@(project-section "Software I Contribute To" %software-contributions)) -- cgit v1.3