Set up gift-guide as its own repo with a pandoc+weasyprint build pipeline
Converts the lead-magnet PDF from a Google Slides export into an editable markdown template, styled to match reground.org's dark theme, with a Makefile convention (make partners/<slug>.pdf) for producing per-partnership customized versions.
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
PANDOC = pandoc
|
||||
PDF_ENGINE = weasyprint
|
||||
TEMPLATE = template.html
|
||||
CSS = style.css
|
||||
PARTNERS = $(patsubst %.md,%.pdf,$(wildcard partners/*.md))
|
||||
|
||||
.PHONY: all clean
|
||||
|
||||
all: template.pdf $(PARTNERS)
|
||||
|
||||
# style.css is linked directly from template.html (not passed via --css),
|
||||
# but listed here so editing it triggers a rebuild of every PDF.
|
||||
%.pdf: %.md $(TEMPLATE) $(CSS)
|
||||
$(PANDOC) $< -o $@ --template=$(TEMPLATE) --pdf-engine=$(PDF_ENGINE) --standalone
|
||||
|
||||
clean:
|
||||
rm -f template.pdf partners/*.pdf
|
||||
Reference in New Issue
Block a user