haccfiles/websites/infra4future.de/default.nix

20 lines
463 B
Nix

{ jekyll, stdenvNoCC, writeScriptBin }:
stdenvNoCC.mkDerivation rec {
name = "infra4future.de-static";
src = ./.;
phases = [ "buildPhase" ];
buildPhase = ''
cd $src
${jekyll}/bin/jekyll build -d $out --disable-disk-cache
'';
watch = writeScriptBin "watch" ''
cd $(git rev-parse --show-toplevel)/websites/infra4future.de
rm -rf /tmp/hacc-website
${jekyll}/bin/jekyll serve --disable-disk-cache -d /tmp/hacc-website "$@"
'';
}