From 26f32903e02694becaf5e61a544ce320af341000 Mon Sep 17 00:00:00 2001 From: Raniere Silva Date: Sun, 19 Apr 2015 12:08:08 -0300 Subject: [PATCH] Add variable to represent Pandoc Pandoc had some changes in the last versions. Having a variable for Pandoc will help maintainers to handle different versions of Pandoc. --- Makefile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 4d38850..6d2b59b 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,5 @@ +PANDOC ?= pandoc + # R Markdown files. SRC_RMD = $(wildcard ??-*.Rmd) DST_RMD = $(patsubst %.Rmd,%.md,$(SRC_RMD)) @@ -43,13 +45,13 @@ preview : $(DST_ALL) # Pattern for slides (different parameters and template). motivation.html : motivation.md _layouts/slides.revealjs Makefile - pandoc -s -t revealjs --slide-level 2 \ + ${PANDOC} -s -t revealjs --slide-level 2 \ --template=_layouts/slides \ -o $@ $< # Pattern to build a generic page. %.html : %.md _layouts/page.html $(FILTERS) - pandoc -s -t html \ + ${PANDOC} -s -t html \ --template=_layouts/page \ --filter=tools/filters/blockquote2div.py \ --filter=tools/filters/id4glossary.py \ @@ -66,6 +68,7 @@ commands : Makefile ## settings : Show variables and settings. settings : + @echo 'PANDOC:' $(PANDOC) @echo 'SRC_RMD:' $(SRC_RMD) @echo 'DST_RMD:' $(DST_RMD) @echo 'SRC_MD:' $(SRC_MD) -- GitLab