From 9b2f42e76944473be269a508c407699d310b81cc Mon Sep 17 00:00:00 2001 From: Paul-Nicolas Madelaine Date: Thu, 21 Sep 2023 02:30:53 +0200 Subject: [PATCH] generate sitemap --- flake.nix | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/flake.nix b/flake.nix index 941e2c4..d181482 100644 --- a/flake.nix +++ b/flake.nix @@ -15,12 +15,26 @@ with ps; [ markdown (pelican.overrideAttrs (_: _: {patches = [./pelican.patch];})) + ( + buildPythonPackage rec { + pname = "pelican-sitemap"; + version = "1.1.0"; + src = pkgs.fetchFromGitHub { + owner = "pelican-plugins"; + repo = "sitemap"; + rev = version; + sha256 = "sha256-GEOLM4wc25VLRZ4qpOENTV6YGfYPHeu95gGdBauJswA="; + }; + format = "pyproject"; + propagatedBuildInputs = [poetry-core]; + } + ) ]); website = pkgs.stdenv.mkDerivation { name = "website"; src = ./.; - nativeBuildInputs = [python]; - buildFlags = ["publish"]; + nativeBuildInputs = [pkgs.libfaketime python]; + buildPhase = "faketime @${builtins.toString self.lastModified} make publish"; installPhase = "cp -r output $out"; }; in {