aboutsummaryrefslogtreecommitdiff
path: root/Makefile
blob: c37182ec4e649cd28ae622d7571d6d962b62e305 (plain)
  1. SITE=_site
  2. SPECVERSION=$(shell perl -ne 'print $$1 if /^version: *([0-9.]+)/' spec.txt)
  3. .PHONY: all clean npm
  4. all: spec.html # spec.pdf spec.md
  5. spec.md: spec.txt tools/template.commonmark
  6. lua tools/make_spec.lua commonmark < $< > $@
  7. spec.html: spec.txt tools/template.html
  8. lua tools/make_spec.lua html < $< > $@
  9. spec.tex: spec.txt tools/template.latex
  10. lua tools/make_spec.lua latex < $< > $@
  11. spec.pdf: spec.tex
  12. xelatex $<
  13. spec.json: spec.txt
  14. python3 test/spec_tests.py --dump-tests < $< > $@
  15. npm:
  16. # Do a sanity check first on versions
  17. grep -q '"version": *"$(SPECVERSION)' package.json && \
  18. npm publish
  19. clean:
  20. -rm spec.tex spec.md spec.html