From 9a1e39743616e83b60d0eea734b5af422562946c Mon Sep 17 00:00:00 2001 From: Orestis Malaspinas <orestis.malaspinas@hesge.ch> Date: Tue, 10 Nov 2020 17:35:49 +0100 Subject: [PATCH] updated makefile --- Makefile | 59 ++++++++------------------------------------------------ 1 file changed, 8 insertions(+), 51 deletions(-) diff --git a/Makefile b/Makefile index 85b2464..95ebd19 100644 --- a/Makefile +++ b/Makefile @@ -15,60 +15,17 @@ REVEALOPTIONS += --self-contained REVEALOPTIONS += -V revealjs-url=./reveal.js REVEALOPTIONS += -V theme=white -all: base_6.pdf base_5.pdf base_4.pdf base_3.pdf base_2.pdf base_1.pdf intro.pdf command_line.pdf index.html +MD=$(wildcard *.md) +HTML=$(MD:%.md=%.html) +PDF=$(MD:%.md=%.pdf) -all_html: intro.html base_1.html base_2.html base_3.html base_4.html base_5.html base_6.html command_line.html +all: $(HTML) $(PDF) -intro.pdf: intro.md metadata.yaml - pandoc $(PDFOPTIONS) -o $@ $^ +%.pdf: %.md metadata.yaml + pandoc -s $(OPTIONS) $(PDFOPTIONS) -o $@ $< -intro.html: intro.md metadata.yaml - pandoc $(REVEALOPTIONS) -o $@ $^ - -base_1.pdf: base_1.md metadata.yaml - pandoc $(PDFOPTIONS) -o $@ $^ - -base_1.html: base_1.md metadata.yaml - pandoc $(REVEALOPTIONS) -o $@ $^ - -base_2.pdf: base_2.md metadata.yaml - pandoc $(PDFOPTIONS) -o $@ $^ - -base_2.html: base_2.md metadata.yaml - pandoc $(REVEALOPTIONS) -o $@ $^ - -base_3.pdf: base_3.md metadata.yaml - pandoc $(PDFOPTIONS) -o $@ $^ - -base_3.html: base_3.md metadata.yaml - pandoc $(REVEALOPTIONS) -o $@ $^ - -base_4.pdf: base_4.md metadata.yaml - pandoc $(PDFOPTIONS) -o $@ $^ - -base_4.html: base_4.md metadata.yaml - pandoc $(REVEALOPTIONS) -o $@ $^ - -base_5.pdf: base_5.md metadata.yaml - pandoc $(PDFOPTIONS) -o $@ $^ - -base_5.html: base_5.md metadata.yaml - pandoc $(REVEALOPTIONS) -o $@ $^ - -base_6.pdf: base_6.md metadata.yaml - pandoc $(PDFOPTIONS) -o $@ $^ - -base_6.html: base_6.md metadata.yaml - pandoc $(REVEALOPTIONS) -o $@ $^ - -command_line.pdf: command_line.md metadata.yaml - pandoc $(PDFOPTIONS) -o $@ $^ - -command_line.html: command_line.md metadata.yaml - pandoc $(REVEALOPTIONS) -o $@ $^ - -index.html: index.md - pandoc -s $(OPTIONS) $(HTMLOPTIONS) -o $@ $< +%.html: %.md metadata.yaml + pandoc -s $(OPTIONS) $(REVEALOPTIONS) -o $@ $< deploy: all all_html mkdir -p prog_seq_c_cours -- GitLab