about summary refs log tree commit diff
path: root/users/wpcarro/website/default.nix
blob: 60d8dc19e768e19750e93ea7451eb26c11b76881 (plain) (blame)
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
{ pkgs, depot, ... }:

rec {
  inherit (depot.users) wpcarro;

  header = "${./fragments/header.html}";
  footer = "${./fragments/footer.html}";
  addendum = "${./fragments/addendum.html}";

  root = pkgs.stdenv.mkDerivation {
    name = "wpcarro.dev";
    src = builtins.path { path = ./.; name = "website"; };
    installPhase = ''
      mkdir -p $out

      cat ${header} \
          ${./fragments/homepage.html} \
          ${footer} \
          ${addendum} > $out/index.html

      mkdir -p $out/habits
      cp -r ${wpcarro.website.habit-screens} $out/habits/index.html

      cp -r ${wpcarro.website.blog.root} $out/blog
    '';
  };
}