From 0df1211ceb11c32c9ab7384f569b94b515dc9dee Mon Sep 17 00:00:00 2001
From: valentin <valentinb@fsmpi.rwth-aachen.de>
Date: Tue, 28 Sep 2021 21:44:25 +0200
Subject: [PATCH] lumi handout: replace template by pure LaTeX

---
 installparty/lumi-handout/.gitignore           |  1 -
 installparty/lumi-handout/compile.py           | 18 ------------------
 .../{handout.tex.template => handout.tex}      | 14 +++++++-------
 3 files changed, 7 insertions(+), 26 deletions(-)
 delete mode 100755 installparty/lumi-handout/compile.py
 rename installparty/lumi-handout/{handout.tex.template => handout.tex} (92%)

diff --git a/installparty/lumi-handout/.gitignore b/installparty/lumi-handout/.gitignore
index 3918b92..f7275bb 100644
--- a/installparty/lumi-handout/.gitignore
+++ b/installparty/lumi-handout/.gitignore
@@ -1,2 +1 @@
-handout.tex
 venv/
diff --git a/installparty/lumi-handout/compile.py b/installparty/lumi-handout/compile.py
deleted file mode 100755
index bf6772f..0000000
--- a/installparty/lumi-handout/compile.py
+++ /dev/null
@@ -1,18 +0,0 @@
-#!/usr/bin/env python3
-from jinja2 import Environment, FileSystemLoader
-import subprocess
-
-if __name__ == "__main__":
-    registration = dict()
-    registration["name"]="\hspace{6cm}"
-    registration["laptop_vendor"]="\hspace{4cm}"
-    registration["optimus"]=False
-    registration["dual_boot"]=False
-
-    sticks = []
-
-    env = Environment(loader=FileSystemLoader("."))
-    template = env.get_template("handout.tex.template")
-    with open("handout.tex","w") as fd:
-        fd.write(template.render({"registration":registration,"sticks":sticks,"cleanhandout":True}))
-    subprocess.call("pdflatex handout.tex && pdflatex handout.tex", shell=True)
diff --git a/installparty/lumi-handout/handout.tex.template b/installparty/lumi-handout/handout.tex
similarity index 92%
rename from installparty/lumi-handout/handout.tex.template
rename to installparty/lumi-handout/handout.tex
index 1a518fa..c7631a0 100644
--- a/installparty/lumi-handout/handout.tex.template
+++ b/installparty/lumi-handout/handout.tex
@@ -35,7 +35,7 @@
 \newcommand{\kopfrechts}{
 	{\large
 	\begin{tabular}{r l}
-		Dein Name: & \underline{{ '{'+registration.name+'}' }}\\
+		Dein Name: & \underline{\hspace{6cm}}\\
 	%	Dein Pizza-Code: & \underline{\hspace{6cm}}\\
 	\end{tabular}
 	}
@@ -257,8 +257,8 @@ Falls gerade kein Helfer verfügbar sein sollte, lies solange den aktuellen \tex
 
 
 \section*{\laufzettel\hfill
-\textbf{Laptop-Modell} \underline{{ '{'+registration.laptop_vendor+'}' }} ~~
-\textbf{\lipstick{} Nr.} \underline{{'{'}}{% if cleanhandout %}\hspace{4cm}{% else %}{% for stick in sticks %} {{stick.typ}}/{{stick.number}} {% endfor %} \hspace{2cm} {% endif %}}{{'}'}}
+\textbf{Laptop-Modell} \underline{\hspace{4cm}} ~~
+\textbf{\lipstick{} Nr.} \underline{\hspace{4cm}}}
 \textbf{Dieser Zettel wird nur von Helfern ausgefüllt.} Bitte gib ihn uns bei der Abmeldung zurück.
 
 \vspace{-1.5em}
@@ -267,8 +267,8 @@ Falls gerade kein Helfer verfügbar sein sollte, lies solange den aktuellen \tex
 {\renewcommand{\arraystretch}{2}
 \begin{center}
 \begin{tabular}{r l l | r l l | r l l}
-\textit{Architektur} & $\square$ 32 Bit \textbf{only} & $\square$ 64 Bit & \textit{EFI} & $\square$ Ja & $\square$ Nein & \textit{NVidia Optimus} & {% if registration.optimus and not cleanhandout %} $\checkmark$ {% else %} $\square$ {% endif %} Ja & {% if not registration.optimus and not cleanhandout %} $\checkmark$ {% else %} $\square$ {% endif %} Nein\\\hline
-\textit{Partitionstabelle} & $\square$ GPT & $\square$ MBR & \textit{Dual-Boot} & {% if registration.dual_boot and not cleanhandout %} $\checkmark$ {% else %} $\square$ {% endif %} Ja & {% if not registration.dual_boot and not cleanhandout %} $\checkmark$ {% else %} $\square$ {% endif %} Nein & \textit{BitLocker} & $\square$ Ja & $\square$ Nein
+\textit{Architektur} & $\square$ 32 Bit \textbf{only} & $\square$ 64 Bit & \textit{EFI} & $\square$ Ja & $\square$ Nein & \textit{NVidia Optimus} &  $\square$  Ja &  $\square$  Nein\\\hline
+\textit{Partitionstabelle} & $\square$ GPT & $\square$ MBR & \textit{Dual-Boot} &  $\square$  Ja &  $\square$  Nein & \textit{BitLocker} & $\square$ Ja & $\square$ Nein
 \end{tabular}
 \end{center}
 }
@@ -313,7 +313,7 @@ $\square$ \large Die Installation wurde komplett \textit{und} erfolgreich abgesc
 
 \begin{widetable}{\textwidth}{c || l}
 	\textbf{Name} & Probleme, Lösungsversuche, Notizen und sonstige Aktionen \\\hline\hline
-{% if not cleanhandout %} {% if registration.windows8 or not registration.rj45 or not registration.backup %} ~~~ LIPCLMS ~~~ & ~~ {% if registration.windows8 %}Windows $\geq$ 8{% endif %} ~~~~  {% if not registration.rj45 %}Keine RJ45-Schnittstelle{% endif %} ~~~~ {% if not registration.backup %}Kein Backup!{% endif %}\\[2ex]\hline {% else %} \hphantom{Gustav} & ~ \\[2ex]\hline {% endif %} {% else %} \hphantom{Gustav} & ~ \\[2ex]\hline {% endif %}
+ \hphantom{Gustav} & ~ \\[2ex]\hline 
 	~ & ~ \hfill \\[2ex]\hline
 	~ & ~ \hfill \\[2ex]\hline
 	~ & ~ \hfill \\[2ex]\hline
@@ -360,4 +360,4 @@ $\square$ \large Die Installation wurde komplett \textit{und} erfolgreich abgesc
 	~ & ~ \hfill \\[2ex]\hline
 	~ & ~ \hfill \\[2ex]\hline
 \end{widetable}
-\end{document}
+\end{document}
\ No newline at end of file
-- 
GitLab