summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2024-06-05 10:48:07 +0200
committerJonas Smedegaard <dr@jones.dk>2024-06-05 11:22:05 +0200
commitadf24d98f4998af3fad6b60647503575df3ed039 (patch)
tree19aedda0581df5f1a740f1c109baeba9b6795b67 /Makefile
parent1605d3018d8689831c7050bd388159b1fa3a84b4 (diff)
add rdfs2dot diagrams, rendered conditionally as SVG or TeX
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile16
1 files changed, 15 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 052f422..9d86a51 100644
--- a/Makefile
+++ b/Makefile
@@ -34,7 +34,9 @@ render: $(ANNOT_TAGS:%=annot/%/index.qmd)
publish:
rsync -avH --delete-after _site/ $(BASE_SSH)
-prepare: $(patsubst %,learn/$(ONTOLOGIES_VERSION)/%.ttl,core $(ONTOLOGIES_LEARN))
+prepare: \
+ $(patsubst %,learn/$(ONTOLOGIES_VERSION)/%.ttl,core $(ONTOLOGIES_LEARN)) \
+ $(foreach dia,tentacular trap,$(foreach ext,svg tex,learn/$(dia)_rdfs.$(ext)))
learn/$(ONTOLOGIES_VERSION)/%.ttl: learn/%.ttl
mkdir --parents learn/0.1
@@ -203,6 +205,18 @@ $(ARTICLES:%=%/b.tex): %/b.tex:
%/core.svg: %/core.puml
plantuml -tsvg $<
+%/rdfs.svg: %/core.ttl
+ rdfs2dot -f turtle $< | dot -Tsvg -o$@
+
+learn/%_rdfs.svg: learn/%.ttl
+ rdfs2dot -f turtle $< | dot -Tsvg -o$@
+
+%/rdfs.tex: %/core.ttl
+ rdfs2dot -f turtle $< | dot2tex --figonly -o$@
+
+learn/%_rdfs.tex: learn/%.ttl
+ rdfs2dot -f turtle $< | dot2tex --figonly -o$@
+
ex/%.puml: ex/%.ttl ex/prefixes.ttl
rdfpuml $<