From 260fa849e3f7e3d023adadaa95ee73a48ef5e3d7 Mon Sep 17 00:00:00 2001 From: Arun Isaac Date: Tue, 14 Jun 2022 14:51:29 +0530 Subject: List closed issues on a separate page. * closed.skb: New file. * index.skb: Link to closed.html instead of listing closed issues. * tissue.scm (#:web-files): Add closed.html. --- closed.skb | 24 ++++++++++++++++++++++++ index.skb | 10 ++++++++-- tissue.scm | 2 ++ 3 files changed, 34 insertions(+), 2 deletions(-) create mode 100644 closed.skb diff --git a/closed.skb b/closed.skb new file mode 100644 index 0000000..8d28dfc --- /dev/null +++ b/closed.skb @@ -0,0 +1,24 @@ +(use-modules (srfi srfi-1) + (srfi srfi-19) + (srfi srfi-28) + (tissue issue) + (tissue web)) + +(define (numbered-issue-listing title-format issues) + (section :title (format title-format (length issues)) + :number #f + (issue-listing (reverse issues)))) + +(document :title "GeneNetwork issue tracker" + (ref :url "https://github.com/genenetwork/gn-gemtext-threads/new/main/issues" + :text "Create new issue") + " | " + (ref :url "team.html" :text "Team agenda view") + " | " + (ref :url "topics.html" :text "Topics") + " | " + (ref :url "https://ci.genenetwork.org" :text "Continuous Integration") + " | " + (ref :url "/topics/links.html" :text "Links") + (numbered-issue-listing "~a closed issues" + (remove issue-open? (issues)))) diff --git a/index.skb b/index.skb index 5c283c5..0651cab 100644 --- a/index.skb +++ b/index.skb @@ -58,5 +58,11 @@ to it." (not (forgotten-issue? issue)) (not (unanswered-issue? issue)))) (issues))) - (numbered-issue-listing "~a closed issues" - (remove issue-open? (issues)))) + (ref :url "/closed.html" + :text (format "~a closed issues" + (fold (lambda (issue result) + (if (issue-open? issue) + result + (1+ result))) + 0 + (issues))))) diff --git a/tissue.scm b/tissue.scm index 81d66bd..67ad3f7 100644 --- a/tissue.scm +++ b/tissue.scm @@ -41,6 +41,8 @@ (copier "style.css")) (file "index.html" (skribe-exporter "index.skb")) + (file "closed.html" + (skribe-exporter "closed.skb")) (file "team.html" (skribe-exporter "team.skb")) (file "topics.html" -- cgit v1.2.3