summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2025-04-10 18:25:30 -0300
committerEuAndreh <eu@euandre.org>2025-04-10 18:27:49 -0300
commite2fee12f06db4f3e4c811c6de8cea54a09129878 (patch)
tree9cd8c563a1d5ae0b40128dd4dd059304841cde37
parentMakefile: Update to latest mkwb(1) sorting (diff)
downloadpapo.im-e2fee12f06db4f3e4c811c6de8cea54a09129878.tar.gz
papo.im-e2fee12f06db4f3e4c811c6de8cea54a09129878.tar.xz
Makefile: Add check-unit-updatedat
-rw-r--r--Makefile11
-rw-r--r--deps.mk10
-rwxr-xr-xmkdeps.sh1
3 files changed, 21 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 924fb1c..266e260 100644
--- a/Makefile
+++ b/Makefile
@@ -289,6 +289,15 @@ check-unit-sorting: src/sort-expected.txt src/sort-given.txt
diff -U10 src/sort-expected.txt src/sort-given.txt
+.SUFFIXES: .updatedat-check
+sources.updatedat-check = $(sources.adoc:.adoc=.updatedat-check)
+$(sources.updatedat-check):
+ . ./$*.conf && if [ -n "$$updatedat_epoch" ] && \
+ [ "$$updatedat_epoch" -le "$$date_epoch" ]; then exit 3; fi
+
+check-unit-updatedat: $(sources.updatedat-check)
+
+
.SUFFIXES: .links-internal-check
sources.links-internal-check = $(sources.adoc:.adoc=.links-internal-check)
$(sources.links-internal-check): $(sources.html)
@@ -302,7 +311,7 @@ check-unit-links-external:
check-unit-links: check-unit-links-internal check-unit-links-external
-check-unit: check-unit-sorting check-unit-links
+check-unit: check-unit-sorting check-unit-updatedat check-unit-links
integration-tests = \
diff --git a/deps.mk b/deps.mk
index d4ace6a..acc6f49 100644
--- a/deps.mk
+++ b/deps.mk
@@ -81,6 +81,16 @@ src/content/incidents/index.snippets.gz: src/content/incidents/index.snippets
src/content/blog/feed.xml.gz: src/content/blog/feed.xml
src/content/incidents/feed.xml.gz: src/content/incidents/feed.xml
+src/content/about.updatedat-check: src/content/about.conf
+src/content/index.updatedat-check: src/content/index.conf
+src/content/pricing.updatedat-check: src/content/pricing.conf
+src/content/privacy.updatedat-check: src/content/privacy.conf
+src/content/terms.updatedat-check: src/content/terms.conf
+src/content/blog/1970/01/01/launch.updatedat-check: src/content/blog/1970/01/01/launch.conf
+src/content/blog/2000/01/01/feature-ann.updatedat-check: src/content/blog/2000/01/01/feature-ann.conf
+src/content/incidents/2000/01/01/service-start.updatedat-check: src/content/incidents/2000/01/01/service-start.conf
+src/content/blog/index.updatedat-check: src/content/blog/index.conf
+src/content/incidents/index.updatedat-check: src/content/incidents/index.conf
src/content/about.links-internal-check: src/content/about.links
src/content/index.links-internal-check: src/content/index.links
src/content/pricing.links-internal-check: src/content/pricing.links
diff --git a/mkdeps.sh b/mkdeps.sh
index 99a3cd7..119b255 100755
--- a/mkdeps.sh
+++ b/mkdeps.sh
@@ -53,6 +53,7 @@ files | sed 's/^\(.*\)\.adoc$/\1.snippets.gz:\t\1.snippets/'
listings | sed 's|^\(.*\)/index\.adoc$|\1/feed.xml.gz:\t\1/feed.xml|'
printf '\n'
+files | sed 's/^\(.*\)\.adoc$/\1.updatedat-check:\t\1.conf/'
files | sed 's/^\(.*\)\.adoc$/\1.links-internal-check:\t\1.links/'
files | sed 's/^\(.*\)\.adoc$/\1.caslinks:\t\1.links/'
printf '\n'