From 6ee3ae5a5f17418966871f62bb17a30bbdd3cad5 Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Sun, 30 Mar 2025 09:38:04 -0300 Subject: Makefile: Add compressed snippets files --- Makefile | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 77c6fc3..f1747f0 100644 --- a/Makefile +++ b/Makefile @@ -67,6 +67,7 @@ sources.adoc = $(articles.adoc) $(listings.adoc) $(pages.adoc) sources.htmlbody = $(sources.adoc:.adoc=.htmlbody) sources.html = $(sources.adoc:.adoc=.html) sources.snippets = $(sources.adoc:.adoc=.snippets) +sources.snippets.gz = $(sources.adoc:.adoc=.snippets.gz) sources.conf = $(sources.adoc:.adoc=.conf) articles.indexentry = $(articles.adoc:.adoc=.indexentry) articles.feedentry = $(articles.adoc:.adoc=.feedentry) @@ -118,6 +119,7 @@ derived-assets = \ $(contents.gz) \ $(sources.htmlbody) \ $(sources.snippets) \ + $(sources.snippets.gz) \ $(sources.conf) \ src/global.conf \ $(listings.htmlheader) \ @@ -135,6 +137,7 @@ derived-assets = \ side-assets = \ src/collections/*/*/*/*/*.html.*.txt \ + src/collections/*/*/*/*/*.html.*.txt.gz \ src/collections/*/index.html.*.txt \ src/collections/*/*.sortdata \ src/pages/*/*.html.*.txt \ @@ -165,6 +168,10 @@ $(contents.gz): gzip -9fk $* touch $@ +$(sources.snippets.gz): + if [ -s $* ]; then gzip -9fk `cat $*`; fi + sed 's/$$/.gz/' $* > $@ + src/content/public.asc: gpg --export --armour "`jq -r '.email' < meta.json`" > $@ -- cgit v1.2.3