From 3b2e6a6fbf15862e7ac9195ab0568b81296733c9 Mon Sep 17 00:00:00 2001 From: david Date: Thu, 16 Nov 2017 12:20:59 +0000 Subject: [PATCH] added the makefile for building the spec --- specification/Makefile | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 specification/Makefile diff --git a/specification/Makefile b/specification/Makefile new file mode 100644 index 0000000..41c117b --- /dev/null +++ b/specification/Makefile @@ -0,0 +1,39 @@ + +# Edit SPECNAME for the name your spec +SPECNAME := disco +# Ensure SPECTOOLS points at your spectools +PANDOC := $(SPECTOOLS)/pandoc +CITEPROC := $(SPECTOOLS)/pandoc-citeproc + +# Use "make", "make html", "make pdf", or "make clean" +all: html pdf + +html: output/$(SPECNAME).html + +pdf: output/$(SPECNAME).pdf + +output/$(SPECNAME).html: $(SPECNAME).md $(PANDOC)/template_pandoc.html $(PANDOC)/spec_markdown.css $(CITEPROC)/ieee-with-url.csl $(CITEPROC)/general.bib my.bib + pandoc $(SPECNAME).md --standalone --toc \ + --from markdown\ + --template $(PANDOC)/template_pandoc.html \ + --metadata=pdfn:$(SPECNAME).pdf \ + --css=spec_markdown.css \ + --filter pandoc-citeproc \ + --bibliography=$(CITEPROC)/general.bib \ + --bibliography=my.bib \ + --csl=$(CITEPROC)/ieee-with-url.csl \ + -o output/$(SPECNAME).html + cp $(PANDOC)/spec_markdown.css output + +output/$(SPECNAME).pdf: $(SPECNAME).md $(PANDOC)/template_pandoc.latex $(CITEPROC)/ieee-with-url.csl $(CITEPROC)/general.bib my.bib + pandoc $(SPECNAME).md --standalone --toc \ + --from markdown\ + --template $(PANDOC)/template_pandoc.latex \ + --filter pandoc-citeproc \ + --bibliography=$(CITEPROC)/general.bib \ + --bibliography=my.bib \ + --csl=$(CITEPROC)/ieee-with-url.csl \ + -o output/$(SPECNAME).pdf + +clean: + rm -f output/$(SPECNAME).html output/spec_markdown.css output/$(SPECNAME).pdf