articles and other creations https://zine.tildeverse.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

41 lines
928 B

  1. ISSUES != find issues -type d
  2. DEST_PDF_FILES := $(ISSUES:issues/%=dist/issue-%.pdf)
  3. DEST_HTML_FILES := $(ISSUES:issues/%=dist/issue-%.html)
  4. PANDOC != command -v pandoc 2> /dev/null
  5. all: $(DEST_PDF_FILES) $(DEST_HTML_FILES)
  6. dist/issue-%.pdf: issues/%
  7. $(PANDOC) \
  8. --file-scope \
  9. --from markdown \
  10. --to latex \
  11. --pdf-engine xelatex \
  12. --table-of-contents \
  13. --variable title:"tildeverse zine $@" \
  14. --standalone \
  15. --output $@ \
  16. $</*.md
  17. dist/issue-%.html: issues/%
  18. $(PANDOC) \
  19. --file-scope \
  20. --from markdown \
  21. --to html \
  22. --standalone \
  23. --table-of-contents \
  24. --lua-filter header-permalinks.lua \
  25. --lua-filter increase-header-levels.lua \
  26. --metadata title:"tildeverse zine $@" \
  27. --variable include-before:"<div class=\"container\">" \
  28. --variable include-after:"</div>" \
  29. --css https://tilde.team/css/hacker.css \
  30. --output $@ \
  31. $</*.md
  32. clean:
  33. rm dist/*.html dist/*.pdf
  34. .PHONY: clean