diff options
author | Eugeniy Mikhailov <evgmik@gmail.com> | 2015-03-13 23:30:15 -0400 |
---|---|---|
committer | Eugeniy Mikhailov <evgmik@gmail.com> | 2015-03-13 23:30:15 -0400 |
commit | 5e6f037190eb203943287895374f89202d9eb29c (patch) | |
tree | 7af10e91162dcc38f65f3f351b8810b521273ada /pandoc.mk | |
parent | 161ec9b9e426d2643bc7659dd5cc18dac99a007c (diff) | |
download | makefile_templates-5e6f037190eb203943287895374f89202d9eb29c.tar.gz makefile_templates-5e6f037190eb203943287895374f89202d9eb29c.zip |
pandoc better handles metadata
Diffstat (limited to 'pandoc.mk')
-rw-r--r-- | pandoc.mk | 15 |
1 files changed, 10 insertions, 5 deletions
@@ -19,10 +19,15 @@ PANDOC_PREPROCESSOR_CMD ?= gpp PANDOC_PREPROCESSOR_OPTIONS ?= -U "" "" "(" "," ")" "(" ")" "\#" "\\" -M "<\#" "\n" " " " " "\n" "(" ")" PANDOC_PREPROCESSOR ?= $(PANDOC_PREPROCESSOR_CMD) $(PANDOC_PREPROCESSOR_OPTIONS) +PANDOC_HTML_METADATA ?= cat - +PANDOC_TEX_METADATA ?= cat - $(CONFIG_DIR)/tex_metadata.yaml +PANDOC_PDF_METADATA ?= $(PANDOC_TEX_METADATA) + PANDOC_COMMON_OPTIONS ?= --standalone --smart -PANDOC_HTML_OPTIONS ?= -s --css=$(TOPDIR)/css_styles/evmik_pandoc.css --section-divs --toc -PANDOC_TEX_OPTIONS ?= +PANDOC_HTML_OPTIONS ?= -s --css=$(TOPDIR)/css_styles/evmik_pandoc.css --section-divs --toc +PANDOC_TEX_OPTIONS ?= --latex-engine=pdflatex PANDOC_PDF_OPTIONS ?= --latex-engine=pdflatex + PANDOC_CMD := pandoc PANDOC := $(PANDOC_CMD) $(PANDOC_COMMON_OPTIONS) @@ -37,13 +42,13 @@ tex_md: $(tex_from_md) $(html_from_md): %.html : %.md $(md_fig_files) $(md_configs) - $(PANDOC_PREPROCESSOR) $< | $(PANDOC) -t html $(PANDOC_HTML_OPTIONS) -o $@ + $(PANDOC_PREPROCESSOR) $< | $(PANDOC_HTML_METADATA) | $(PANDOC) -t html $(PANDOC_HTML_OPTIONS) -o $@ $(tex_from_md): %.tex : %.md $(md_fig_files) $(md_configs) - $(PANDOC_PREPROCESSOR) $< | $(PANDOC) -t latex $(PANDOC_TEX_OPTIONS) -o $@ + $(PANDOC_PREPROCESSOR) $< | $(PANDOC_TEX_METADATA) | $(PANDOC) -t latex $(PANDOC_TEX_OPTIONS) -o $@ $(pdf_from_md): %.pdf : %.md $(md_fig_files) $(md_configs) - $(PANDOC_PREPROCESSOR) $< | $(PANDOC) $(PANDOC_PDF_OPTIONS) -o $@ + $(PANDOC_PREPROCESSOR) $< | $(PANDOC_PDF_METADATA) | $(PANDOC) $(PANDOC_PDF_OPTIONS) -o $@ dest_dir_md: |