blob: 97cf089addfce3616d7dd7b59f573eb27ec9f970 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
{ self, ... }:
{
perSystem =
{ ... }:
{
websites.${self.domain} =
{ lib, ... }:
let
inherit (lib) mkOption types;
in
{
files =
let
root = ./html;
files = with lib.fileset; toList root;
redirects =
with lib;
mapAttrsToList
(name: value: {
name = head value.locations;
inherit value;
})
{
kindertag = {
path = ./html/Kalender/Kindertag-in-der-Mehrwertkultur.html;
locations = [
"Kalender/Kindertag-in-der-Mehrwertkultur.html"
"Kalender/Kindertag in der Mehrwertkultur.html"
];
};
kinder-banner = {
path = ./html/Kalender/Kindertag-in-der-Mehrwertkultur_html_7312c2696b940296.png;
locations = [
"Kalender/Kindertag-in-der-Mehrwertkultur_html_7312c2696b940296.png"
"Kalender/Kindertag in der Mehrwertkultur_html_7312c2696b940296.png"
];
};
contraZt-logo = {
path = ./html/Kalender/Kindertag-in-der-Mehrwertkultur_html_290e08fdf9314385.jpg;
locations = [
"Kalender/Kindertag-in-der-Mehrwertkultur_html_290e08fdf9314385.jpg"
"Kalender/Kindertag in der Mehrwertkultur_html_290e08fdf9314385.jpg"
];
};
};
in
lib.listToAttrs (
redirects
++ map (file: {
name = lib.path.removePrefix root file;
value = lib.mkDefault file;
}) files
);
};
};
}
|