about summary refs log tree commit diff
path: root/web
diff options
context:
space:
mode:
authorVincent Ambo <mail@tazj.in>2021-11-05T13·34+0100
committerVincent Ambo <mail@tazj.in>2021-12-01T09·37+0300
commit8318178b5f34bae0d625ada1170006cb2d6a6a51 (patch)
treefd9dc85b31e0b4e3b0514e670119caddd0bf8740 /web
parent79681c9e219c8dd2cc6690b78fce6bb48dcd10e1 (diff)
feat(web/tvl): List blog posts on homepage r/3124
Change-Id: Ic0ee18466fbaca1a374e7489be640f49571eb9c5
Diffstat (limited to 'web')
-rw-r--r--web/tvl/default.nix15
1 files changed, 14 insertions, 1 deletions
diff --git a/web/tvl/default.nix b/web/tvl/default.nix
index be0981eec2af..ee012ca4096a 100644
--- a/web/tvl/default.nix
+++ b/web/tvl/default.nix
@@ -7,6 +7,9 @@ let
   inherit (pkgs) graphviz runCommandNoCC writeText;
   inherit (depot.web) atom-feed blog tvl;
 
+  listPosts = defun [ (list blog.post) string ] (posts:
+    lib.concatStringsSep "\n" (map (p: "* [${p.title}](blog/${p.key})") posts)
+  );
 
   postRenderingCommands = defun [ (list blog.post) string ] (posts:
     lib.concatStringsSep "\n"
@@ -71,7 +74,17 @@ let
       [tvl-xmpp]: xmpp:#tvl@irc.hackint.org?join
       [tvl-webchat]: https://webirc.hackint.org/#ircs://irc.hackint.org/#tvl
 
-      <hr>
+      ----------------
+
+      ## Blog
+
+      Here are the most recent TVL blog posts.
+
+      ${listPosts publishedPosts}
+
+      You can also follow our [atom feed](https://tvl.fyi/feed.atom).
+
+      ----------------
 
       ## Where did all these people come from?