aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2024-04-28 09:54:02 +0200
committerJonas Smedegaard <dr@jones.dk>2024-04-28 09:54:02 +0200
commita11d7fdf8277d0a340238fb16b75dcc75b6bcc5c (patch)
treeb5c1dd9fafef9e477a6e56bab8382c2824a6b6b6 /Makefile
parentd28f24cc6473d6279584cce203bc9e102f65a324 (diff)
generalize ontology targets
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile22
1 files changed, 12 insertions, 10 deletions
diff --git a/Makefile b/Makefile
index c9523dc..922ef17 100644
--- a/Makefile
+++ b/Makefile
@@ -7,6 +7,8 @@ BASE_IRI = https://thoughtroam.abcdefghijklmnopqrstuvxyzæøå.dk/
PAD_ARTICLES = worlding
ARTICLES = worlding
+ONTOLOGIES = learning
+
PERL_FILES = bin/hedgedoc2quarto bin/xmp2rdfxml
TIDY_MARKDOWN = worlding
@@ -146,17 +148,17 @@ $(ARTICLES:%=%/b.tex): %/b.tex:
mv --force $*/index.tex $@
rm --force _site/b.pdf
-rdf/learning.svg: rdf/learning.sdm
- cd rdf && sdml draw --diagram concepts -i learning.sdm -f svg -o learning.svg
+$(ONTOLOGIES:%=rdf/%.svg): rdf/%.svg: rdf/%.sdm
+ cd rdf && sdml draw --diagram concepts -i $*.sdm -f svg -o $*.svg
-rdf/learning-er.svg: rdf/learning.sdm
- cd rdf && sdml draw --diagram entity-relationship -i learning.sdm -f svg -o learning-er.svg
+$(ONTOLOGIES:%=rdf/%-er.svg): rdf/%-er.svg: rdf/%.sdm
+ cd rdf && sdml draw --diagram entity-relationship -i $*.sdm -f svg -o $*-er.svg
-rdf/learning-uml.svg: rdf/learning.sdm
- cd rdf && sdml draw --diagram uml-class -i learning.sdm -f svg -o learning-uml.svg
+$(ONTOLOGIES:%=rdf/%-uml.svg): rdf/%-uml.svg: rdf/%.sdm
+ cd rdf && sdml draw --diagram uml-class -i $*.sdm -f svg -o $*-uml.svg
-rdf/learning.rdf: rdf/learning.sdm
- cd rdf && sdml convert -i learning.sdm -f rdf -o learning.rdf --no-color
+$(ONTOLOGIES:%=rdf/%.rdf): rdf/%.rdf: rdf/%.sdm
+ cd rdf && sdml convert -i $*.sdm -f rdf -o $*.rdf --no-color
-rdfs-graf-of-learning:
- sdml convert -f rdf -i rdf/learning.sdm --no-color | rdfs2dot | dot -Tx11
+$(ONTOLOGIES:%=rdfs-graf-of-%): rdfs-graf-of-%: rdf/%.sdm
+ sdml convert -f rdf -i $< --no-color | rdfs2dot | dot -Tx11