blob: 5372f6bab2698b1ba51a0c2f2ef37bc0bd967694 (
plain)
- pandoc_sources := $(wildcard *.mkd)
- presentations = $(pandoc_sources:%.mkd=%/index.html)
- all: $(presentations)
- # TODO: use --offline when working with Debian packaging of Pandoc
- # FIXME: only add local stylesheet if it already exist in target dir
- $(presentations): %/index.html : %.mkd %/local.css
- mkdir -p $(dir $@)
- pandoc --from Markdown --to Slidy -o $@ -s -c local.css $<
- perl -i -pe 's{https?://www.w3.org/Talks/Tools/Slidy2/(?:styles|scripts)/(slidy.(?:css|js))(?:\.gz)?}{../../../slidy/$$1}g' $@
- %/local.css: $(firstword $(wildcard local.scss local.css) ../../slidy/local.css)
- #%/local.css: local.scss
- #%/local.css: $(wildcard local.scss)
- $(if $(filter %.scss,$<),\
- rm --force $@ && \
- sassc --load-path /usr/share/sass/stylesheets --style compressed $< $@,\
- ln --force --symbolic --target-directory=$* ../$<)
|