From d7507c1fbae1362bfb4525b074061a5303a9cc71 Mon Sep 17 00:00:00 2001 From: Trygve Laugstøl Date: Wed, 18 Apr 2018 08:47:15 +0200 Subject: wip --- Makefile | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 Makefile (limited to 'Makefile') 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 -- cgit v1.2.3