commit: e2a1a87742082a026e701bb37c58b076ea937cd8
parent 1201fb0562ee358c1ad68f7ca60fc91f926e749c
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date: Thu, 9 Mar 2023 00:30:22 +0100
ninja: Avoid pipes for articles
Diffstat:
5 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/.gitignore b/.gitignore
@@ -3,3 +3,4 @@
config.php
datalove
/bookmarks.xsl
+/entry.xsl
diff --git a/build.ninja b/build.ninja
@@ -7,7 +7,7 @@ rule xslt
command = xsltproc --nonet --xincludestyle --xinclude -o $out $in
rule article
- command = xsltproc --nonet --param feedURL "'https://hacktivis.me/feed.atom'" $in | xmllint --xinclude --encode utf-8 --nofixup-base-uris --nsclean - | sed '1d' >|$out
+ command = xsltproc --nonet --param feedURL "'https://hacktivis.me/feed.atom'" -o $out $in
rule notes_index
command = ./notes_index.pm >|$out
diff --git a/config.ninja b/config.ninja
@@ -5,6 +5,7 @@ rule gen_config
build config.ninja: gen_config configure | ./articles
+build entry.xsl: xinclude entry.xsl.in | ./templates/head.xml ./templates/en/nav.xsl ./templates/en/footer.shtml
build bookmarks.xsl: xinclude bookmarks.xsl.in | ./templates/head.xml ./templates/en/nav.xsl ./templates/en/footer.shtml
build bookmarks.html: xslt bookmarks.xsl bookmarks.xbel
-build articles/2022$ Summary.html: article entry.xsl articles/2022$ Summary.xml | ./templates/head.xml ./templates/en/nav.xsl ./templates/en/footer.shtml
+build articles/2022$ Summary.html: article entry.xsl articles/2022$ Summary.xml
diff --git a/configure b/configure
@@ -9,6 +9,7 @@ rule gen_config
build config.ninja: gen_config configure | ./articles
+build entry.xsl: xinclude entry.xsl.in | ${templates_en}
build bookmarks.xsl: xinclude bookmarks.xsl.in | ${templates_en}
build bookmarks.html: xslt bookmarks.xsl bookmarks.xbel
EOF
@@ -17,5 +18,5 @@ for i in articles/*.xml
do
i="${i//$/\$\$}" # '$' → '$$'
i="${i// /$ }" # ' ' → '$ '
- echo "build ${i//.xml/.html}: article entry.xsl ${i} | ${templates_en}"
+ echo "build ${i//.xml/.html}: article entry.xsl ${i}"
done >>config.ninja
diff --git a/entry.xsl b/entry.xsl.in