aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2018-04-18 08:47:15 +0200
committerTrygve Laugstøl <trygvis@inamo.no>2018-04-18 08:47:15 +0200
commitd7507c1fbae1362bfb4525b074061a5303a9cc71 (patch)
treec98b8b0591f7e14535a6f43d9914ffca5b6e6ff4 /Makefile
downloadiot-workshop-ndc-2018-d7507c1fbae1362bfb4525b074061a5303a9cc71.tar.gz
iot-workshop-ndc-2018-d7507c1fbae1362bfb4525b074061a5303a9cc71.tar.bz2
iot-workshop-ndc-2018-d7507c1fbae1362bfb4525b074061a5303a9cc71.tar.xz
iot-workshop-ndc-2018-d7507c1fbae1362bfb4525b074061a5303a9cc71.zip
wip
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile48
1 files changed, 48 insertions, 0 deletions
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..dda4b16
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,48 @@
+P=what-is-iot
+# Madrid Pittsburgh boxes
+SLIDE_THEME=boxes
+PDFS=$(P)-text.pdf $(P)-slides.pdf
+HTMLS=$(P)-reveal.html
+
+RUN_PANDOC_BEAMER=pandoc -f markdown -t beamer --highlight-style=pygments -V theme:$(SLIDES_THEME)\
+ --pdf-engine=xelatex
+RUN_PANDOC_REVEALJS=pandoc -f markdown -t revealjs -s -V revealjs-url=./bower_components/reveal.js
+
+all: $(PDFS) $(HTMLS)
+
+slides: $(P)-slides.pdf
+html: $(P)-reveal.html
+.PHONY: html slides
+
+clean:
+ rm -f $(PDFS) $(HTMLS)
+
+spell: .$(P).md.spell
+
+.$(P).md.spell: $(P).md
+
+.%.spell: %
+ aspell --home-dir=. --personal=dictionary.txt --lang=en_US check $<
+ touch $@
+
+$(P).md: Makefile
+ @touch $@
+
+%-text.pdf: %.md
+ pandoc -f markdown -o $@ $<
+
+%-slides.pdf: %.md
+ $(RUN_PANDOC_BEAMER) -o $@ $<
+
+%-reveal.html: %.md
+ $(RUN_PANDOC_REVEALJS) -o $@ $<
+
+images/%.pdf: images/%.tex | Makefile
+ pdflatex -output-directory=images $<
+# pdfcrop $@
+# mv $(patsubst %.pdf,%-crop.pdf,$@) $@
+
+# Dependencies
+$(P).md: images/IP-Header_eng.pdf
+$(P).md: images/ip-header.pdf
+$(P).md: images/ip-header.svg