diff options
| -rw-r--r-- | templates/quiz/.gitignore | 2 | ||||
| -rw-r--r-- | templates/quiz/Makefile | 17 | ||||
| -rw-r--r-- | templates/quiz/q.tex | 11 | ||||
| -rw-r--r-- | templates/quiz/solutions.csv | 1 |
4 files changed, 31 insertions, 0 deletions
diff --git a/templates/quiz/.gitignore b/templates/quiz/.gitignore new file mode 100644 index 00000000..225c3815 --- /dev/null +++ b/templates/quiz/.gitignore @@ -0,0 +1,2 @@ +*.png +*.jpg diff --git a/templates/quiz/Makefile b/templates/quiz/Makefile new file mode 100644 index 00000000..1d424dec --- /dev/null +++ b/templates/quiz/Makefile @@ -0,0 +1,17 @@ +QUESTIONS:=$(wildcard *.tex) +PDFS:=$(QUESTIONS:.tex=.pdf) +PNGS:=$(QUESTIONS:.tex=.png) +JPGS:=$(QUESTIONS:.tex=.jpg) + +.PHONY: all +all: $(PDFS) $(PNGS) $(JPGS) + +%.jpg: %.pdf + convert -density 600 -quality 100 $< -flatten -sharpen 0x1.0 $@ + +%.png: %.pdf + convert -density 600 -quality 100 $< -flatten -sharpen 0x1.0 $@ + +COMMON_MK = $(shell bash -c 'upfind() { [[ -f "$$1" ]] && printf "$$1" || ([ "$$(realpath $$(dirname "$$1"))" == "/" ] || upfind "../$$1") }; upfind common.mk') +include $(COMMON_MK) + diff --git a/templates/quiz/q.tex b/templates/quiz/q.tex new file mode 100644 index 00000000..5f527c26 --- /dev/null +++ b/templates/quiz/q.tex @@ -0,0 +1,11 @@ +\documentclass[margin=0.2cm, varwidth]{standalone} + +\begin{document} +\centering +Frage: $1^2 = ?$ \newline + +\begin{tabular}{c c c c} +a) & b) & c) & d) \\ +11 & 1 & 2 & -1 \\ +\end{tabular} +\end{document} diff --git a/templates/quiz/solutions.csv b/templates/quiz/solutions.csv new file mode 100644 index 00000000..cf05410b --- /dev/null +++ b/templates/quiz/solutions.csv @@ -0,0 +1 @@ +q,B |
