Build pelican sites without publishconf

This commit is contained in:
randogoth 2026-02-07 20:58:27 +02:00
parent 7b6329be07
commit ad0377ab84

View file

@ -22,17 +22,11 @@ let
runHook preBuild
cd ${workdir}
${copyPlugins}
conf=""
if [ -f publishconf.py ]; then
conf="publishconf.py"
elif [ -f pelicanconf.py ]; then
conf="pelicanconf.py"
if [ -d content ]; then
# Drop draft content before building (Pelican draft detection can be inconsistent).
grep -RIl '^status:[[:space:]]*draft' content | xargs -r rm -f
fi
if [ -n "$conf" ]; then
${pythonEnv}/bin/pelican content -o "$out" -s "$conf"
else
${pythonEnv}/bin/pelican content -o "$out"
fi
runHook postBuild
'';
installPhase = "true";