Context
While implementing the review follow-ups for the add-litprog-java-factory-tutorial branch, I checked the new slide wrapper src/slides-tutorial-java.tex against the existing src/slides-intro.tex.
Observation
The two files are near-identical Beamer wrappers:
src/slides-intro.tex
src/slides-tutorial-java.tex
They currently differ only in which content file they \input:
slides-intro.tex inputs contents.tex
slides-tutorial-java.tex inputs factory.tex
Everything else in the wrapper is duplicated.
Why it matters
This is not a correctness bug today, but it creates a small maintenance trap. If the shared Beamer setup changes later, every wrapper copy has to be updated by hand. The duplication is still manageable with two files, but it becomes more awkward if another slide deck is added.
Evidence
Current file contents are both 12-line wrappers with the same structure:
src/slides-intro.tex
src/slides-tutorial-java.tex
The only material difference is the \input{...} target.
Suggested follow-up
Introduce a shared wrapper, for example _slides-wrapper.tex, and let each concrete slide target set only the content file to include.
One possible pattern is:
- each deck-specific file defines a macro such as
\def\slidecontent{contents.tex} or \def\slidecontent{factory.tex}
- the shared wrapper performs the common Beamer setup once
- the shared wrapper inputs
\slidecontent
That would keep the per-deck files minimal while avoiding repeated boilerplate.
Context
While implementing the review follow-ups for the
add-litprog-java-factory-tutorialbranch, I checked the new slide wrappersrc/slides-tutorial-java.texagainst the existingsrc/slides-intro.tex.Observation
The two files are near-identical Beamer wrappers:
src/slides-intro.texsrc/slides-tutorial-java.texThey currently differ only in which content file they
\input:slides-intro.texinputscontents.texslides-tutorial-java.texinputsfactory.texEverything else in the wrapper is duplicated.
Why it matters
This is not a correctness bug today, but it creates a small maintenance trap. If the shared Beamer setup changes later, every wrapper copy has to be updated by hand. The duplication is still manageable with two files, but it becomes more awkward if another slide deck is added.
Evidence
Current file contents are both 12-line wrappers with the same structure:
src/slides-intro.texsrc/slides-tutorial-java.texThe only material difference is the
\input{...}target.Suggested follow-up
Introduce a shared wrapper, for example
_slides-wrapper.tex, and let each concrete slide target set only the content file to include.One possible pattern is:
\def\slidecontent{contents.tex}or\def\slidecontent{factory.tex}\slidecontentThat would keep the per-deck files minimal while avoiding repeated boilerplate.