summary refs log tree commit diff
diff options
context:
space:
mode:
authorArun Isaac2022-06-14 14:51:29 +0530
committerArun Isaac2022-06-14 14:53:10 +0530
commit260fa849e3f7e3d023adadaa95ee73a48ef5e3d7 (patch)
treed7f4c69cf88f7768635390c2a0509255cb7461ee
parent5367b6cd8149b69000b252a776110e64c60917d4 (diff)
downloadgn-gemtext-260fa849e3f7e3d023adadaa95ee73a48ef5e3d7.tar.gz
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.
-rw-r--r--closed.skb24
-rw-r--r--index.skb10
-rw-r--r--tissue.scm2
3 files changed, 34 insertions, 2 deletions
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"