Ein Spiel zum Dinge-"durch-die-Blume"-Erklären und Um-die-Ecke-Denken. http://gitea.felics.kettenbruch.de/felics/Spiel_Kontakt/src/branch/master/Spiel_Kontakt_Anleitung.md

Makefile 2.2KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. #!/usr/bin/env make
  2. # The executables mentioned here are provided by the following packages (on Artix/ Arch Linux):
  3. # (Syntax here: `* <executable>: <package>`)
  4. # * mkdcat: mdcat
  5. # * pandoc: pandoc
  6. # * multimnarkdown: multimnarkdown
  7. # * mkd2html: discount
  8. # * markdown: discount
  9. # * mkd2pdf: mkd2pdf
  10. TEXTFILE_BASENAME=Spiel_Kontakt_Anleitung
  11. SOURCE_MD=$(TEXTFILE_BASENAME).md
  12. .PHONY: all clean txt tex context html html-snippet pdf
  13. all: txt tex context html html-snippet pdf
  14. clean:
  15. rm -f $(TEXTFILE_BASENAME).txt $(TEXTFILE_BASENAME).tex $(TEXTFILE_BASENAME).context $(TEXTFILE_BASENAME).html $(TEXTFILE_BASENAME).snippet.html $(TEXTFILE_BASENAME).pdf
  16. txt: $(TEXTFILE_BASENAME).txt
  17. tex: $(TEXTFILE_BASENAME).tex
  18. context: $(TEXTFILE_BASENAME).context
  19. html: $(TEXTFILE_BASENAME).html
  20. html-snippet: $(TEXTFILE_BASENAME).snippet.html
  21. pdf: $(TEXTFILE_BASENAME).pdf
  22. $(TEXTFILE_BASENAME).txt: $(SOURCE_MD)
  23. # mdcat -c no $(SOURCE_MD) > $(TEXTFILE_BASENAME).txt
  24. pandoc -f markdown -s -o $(TEXTFILE_BASENAME).txt $(SOURCE_MD)
  25. $(TEXTFILE_BASENAME).tex: $(SOURCE_MD)
  26. # multimarkdown -t latex -s -o $(TEXTFILE_BASENAME).tex --lang=de $(SOURCE_MD)
  27. pandoc -f markdown -t latex -H LaTeX_additional_preamble.tex -s -o $(TEXTFILE_BASENAME).tex $(SOURCE_MD) # Try xelatex to compile.
  28. $(TEXTFILE_BASENAME).context: $(SOURCE_MD)
  29. pandoc -f markdown -t context -s -o $(TEXTFILE_BASENAME).context $(SOURCE_MD)
  30. $(TEXTFILE_BASENAME).html: $(SOURCE_MD)
  31. mkd2html $(SOURCE_MD)
  32. # pandoc -f markdown -t html4 -s -o $(TEXTFILE_BASENAME).html $(SOURCE_MD)
  33. $(TEXTFILE_BASENAME).snippet.html: $(SOURCE_MD)
  34. markdown -o $(TEXTFILE_BASENAME).snippet.html $(SOURCE_MD)
  35. # pandoc -f markdown -t html4 -o $(TEXTFILE_BASENAME).html $(SOURCE_MD)
  36. $(TEXTFILE_BASENAME).pdf: $(SOURCE_MD) $(TEXTFILE_BASENAME).tex # $(TEXTFILE_BASENAME).html
  37. # mkd2pdf $(SOURCE_MD)
  38. # pandoc -s -f markdown --pdf-engine=wkhtmltopdf -M 'pagetitle=Anleitung Spiel "Kontakt"' -o $(TEXTFILE_BASENAME).pdf $(SOURCE_MD)
  39. # wkhtmltopdf -s A4 -O portrait -T 2cm -B 2cm -L 1.5cm -R 1.5cm --title 'Anleitung Spiel "Kontakt"' $(TEXTFILE_BASENAME).html $(TEXTFILE_BASENAME).pdf
  40. # pdflatex $(TEXTFILE_BASENAME).tex
  41. # rm -f $(TEXTFILE_BASENAME).log $(TEXTFILE_BASENAME).aux
  42. latexmk -gg -pdf $(TEXTFILE_BASENAME).tex
  43. latexmk -c $(TEXTFILE_BASENAME).tex