Skip to content

Commit

Permalink
Build overlay and print versions in parallel
Browse files Browse the repository at this point in the history
  • Loading branch information
mmarx committed Jun 19, 2017
1 parent 2974432 commit b859922
Show file tree
Hide file tree
Showing 15 changed files with 116 additions and 43 deletions.
18 changes: 4 additions & 14 deletions Vorlesungen/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,24 +5,14 @@
# Usage sh build.sh <lectureNumberAsString>

fileprefix="TheoLog2017-Vorlesung-" # the start of generated PDFs
tmpfilename="`mktemp tmplecturefile-XXX`" # generate a name that doesn't collide with anything present

inputfilename=lecture-${1}.tex
printfilename=${fileprefix}${1}-print.pdf
overlayfilename=${fileprefix}${1}-overlay.pdf

echo '\documentclass[onlymath,handout]{beamer}' > ${tmpfilename}.tex
tail -n +3 lecture-${1}.tex >> ${tmpfilename}.tex
latexmk -lualatex ${tmpfilename}.tex
latexmk -c ${tmpfilename}.tex
pdfnup --nup 2x2 --outfile ${printfilename} ${tmpfilename}.pdf

echo '\documentclass[onlymath]{beamer}' > ${tmpfilename}.tex
tail -n +3 lecture-${1}.tex >> ${tmpfilename}.tex
latexmk -lualatex ${tmpfilename}.tex
latexmk -c ${tmpfilename}.tex
mv ${tmpfilename}.pdf ${overlayfilename}

rm ${tmpfilename} ${tmpfilename}.*
latexmk -lualatex -pdflatex="lualatex --shell-escape %O %S" ${inputfilename}
cp lecture-${1}-print.pdf ${printfilename}
cp lecture-${1}.pdf ${overlayfilename}

echo
echo
Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-01.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-02.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-03.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-04.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-05.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-06.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-07.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
11 changes: 8 additions & 3 deletions Vorlesungen/lecture-08.tex
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}

\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother
\input{macros-lecture}

\defineTitle{8}{Beziehungen zwischen Komplexitätsklassen / Effizient lösbare Probleme}{3. Mai 2017}
Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-09.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-10.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-11.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-12.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-13.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down
10 changes: 8 additions & 2 deletions Vorlesungen/lecture-14.tex
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
\documentclass[onlymath]{beamer}
% \documentclass[onlymath,handout]{beamer}
\newcommand*{\BeamerSuffix}{-overlay}
\newcommand*{\HandoutSuffix}{-print}
\PassOptionsToClass{onlymath}{beamer}
\documentclass[also={handout}]{beamerswitch}
\handoutlayout{nup=4}
\makeatletter
\beamer@ignorenonframefalse
\makeatother

\input{macros-lecture}

Expand Down

0 comments on commit b859922

Please sign in to comment.