fix build

This commit is contained in:
2025-06-01 11:04:32 +08:00
parent 4428883892
commit a1f6487f81

View File

@@ -1,13 +1,19 @@
{ stdenv, hextra, hugo }: stdenv.mkDerivation
{ lib, stdenv, hextra, hugo, buildProxy ? null }: stdenv.mkDerivation
{
name = "blog";
src = ./.;
nativeBuildInputs = [ hugo ];
preBuild = lib.optionalString (buildProxy != null) ''source ${buildProxy}'';
configurePhase =
''
mkdir themes
ln -s ${hextra} themes/hextra
'';
buildPhase = "hugo";
buildPhase =
''
runHook preBuild
hugo
runHook postBuild
'';
installPhase = "cp -r public $out";
}