diff options
| author | quentin@aristote.fr <quentin@aristote.fr> | 2023-09-30 21:25:03 +0200 |
|---|---|---|
| committer | quentin@aristote.fr <quentin@aristote.fr> | 2023-09-30 21:25:03 +0200 |
| commit | 1036c49e9e3c3ff311a713cccf0054c8c16a9857 (patch) | |
| tree | 8a9495eb0181cef35f690879267120bc3de3defe /html/software/default.nix | |
| parent | add6bcd3c1984068e7122fa07a8f3e35ebaf58a9 (diff) | |
format
Diffstat (limited to 'html/software/default.nix')
| -rw-r--r-- | html/software/default.nix | 39 |
1 files changed, 23 insertions, 16 deletions
diff --git a/html/software/default.nix b/html/software/default.nix index 49f4627..9d42345 100644 --- a/html/software/default.nix +++ b/html/software/default.nix @@ -1,27 +1,34 @@ -{ html, data, lib, ... }: - -let +{ + html, + data, + lib, + ... +}: let software = data.software; format = softwarePiece: with html; with softwarePiece; - { - inherit id title abstract; - url = URL; - } // (let - authorsOther = lib.remove data.basics.name - (builtins.map (author: "${author.given} ${author.family}") author); - in lib.optionalAttrs (authorsOther != [ ]) { - authors = "With ${lib.concatStringsSep ", " authorsOther}"; - }); + { + inherit id title abstract; + url = URL; + } + // (let + authorsOther = + lib.remove data.basics.name + (builtins.map (author: "${author.given} ${author.family}") author); + in + lib.optionalAttrs (authorsOther != []) { + authors = "With ${lib.concatStringsSep ", " authorsOther}"; + }); in { title = "Software"; priority = 15; body = with html; - dl (for (sort.byPath [ "title" ] software) (softwarePiece: - let formatted = format softwarePiece; - in with formatted; [ - (dt { id = "Software#${id}"; } (href { target = "_blank"; } url title)) + dl (for (sort.byPath ["title"] software) (softwarePiece: let + formatted = format softwarePiece; + in + with formatted; [ + (dt {id = "Software#${id}";} (href {target = "_blank";} url title)) (dd abstract) ])); } |
