tvl-depot/tvix/website/default.nix
Florian Klink afe4dfb61e refactor(tvix): move logo to //tvix:logo
Also expose both formats, then use it from
users/tazjin/presentations/tvix-eval-2023.

Change-Id: Id906e8aff5510a7a4f33336326472e86db18ea32
Reviewed-on: https://cl.tvl.fyi/c/depot/+/9280
Tested-by: BuildkiteCI
Autosubmit: flokli <flokli@flokli.de>
Reviewed-by: tazjin <tazjin@tvl.su>
2023-09-10 13:13:14 +00:00

32 lines
920 B
Nix

{ depot, lib, pkgs, ... }:
let
# https://developers.google.com/search/docs/advanced/structured-data/logo
structuredData = {
"@context" = "https://schema.org";
"@type" = "Organisation";
url = "https://tvl.fyi";
logo = "https://static.tvl.fyi/latest/logo-animated.svg";
};
# All Tvix-related blog posts from the main TVL website
tvixPosts = builtins.filter
(post: !(post.draft or false) && (lib.hasInfix "Tvix" post.title))
depot.web.tvl.blog.posts;
postListEntries = map (p: "* [${p.title}](https://tvl.fyi/blog/${p.key})") tvixPosts;
landing = depot.web.tvl.template {
title = "Tvix - A new implementation of Nix";
content = ''
${builtins.readFile ./landing-en.md}
${builtins.concatStringsSep "\n" postListEntries}
'';
};
in
pkgs.runCommand "tvix-website" { } ''
mkdir $out
cp ${landing} $out/index.html
cp ${depot.tvix.logo}/logo.webp $out/
''