Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
1 changed file
with
60 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
# Makefile for Markdown files via Pandoc | ||
# Modified for the Final Year Project build | ||
|
||
# TODO: ------------- (If we have multiple Inputs) ------------- | ||
# If we have multiple inputs we we can stick them here | ||
# NOTE, It is important they are in order | ||
# Again we can pass this through the command line | ||
SOURCES = | ||
TARGET = | ||
|
||
#Give options for creating either Presentations or Reports | ||
#Just comment this line out to switch. | ||
# Alternatively run with Make <whatever> PRES= | ||
PRES=0 | ||
|
||
#Reveal | ||
#pandoc -t revealjs -V revealjs-url=http://lab.hakim.se/reveal-js --standalone --self-contained presentation.md -o presentation.html | ||
|
||
#I think I quite Like Slideous | ||
|
||
|
||
|
||
ifdef PRES | ||
#Presentations | ||
PDF_PANDOC_OPTIONS = -f markdown+native_divs -t beamer -V theme:metropolis | ||
HTML_PANDOC_OPTIONS = -t revealjs -V revealjs-url=http://lab.hakim.se/reveal-js --standalone | ||
else | ||
#Reports | ||
PDF_PANDOC_OPTIONS = --filter=pandoc-citeproc | ||
endif | ||
|
||
#Default Sources to the input provide | ||
ifndef SOURCES | ||
SOURCES = $< | ||
endif | ||
|
||
ifndef TARGET | ||
TARGET = $@ | ||
endif | ||
|
||
#Build a PDF from the relevant sources | ||
%.pdf: %.md | ||
# Old way of doing it, now dealt with through target | ||
# #pandoc $(PANDOC_OPTIONS) -o $@ $< | ||
pandoc $(PDF_PANDOC_OPTIONS) $(SOURCES) -o $(TARGET) | ||
|
||
|
||
%.html: %.md | ||
# #pandoc -t revealjs -V revealjs-url=http://lab.hakim.se/reveal-js $(SOURCES) -o $(TARGET) | ||
pandoc $(HTML_PANDOC_OPTIONS) $(SOURCES) -o $(TARGET) | ||
|
||
|
||
# #%.tex: $(SOURCES) | ||
|
||
# #Helper method to make all will create target | ||
# all: $(SOURCES) $(TARGET) | ||
|
||
|
||
# .PHONY: all | ||
#pandoc -t revealjs -V revealjs-url=http://lab.hakim.se/reveal-js |