I have an abbrev.tex file that used in another file project.tex through
\input{abbrev}
Today for some reason, abbrev.tex is missing (I may have deleted it accidentally).
I tried compile project.tex using pdflatex and it keeps complaining that command not found.
I wasted about 30 mins before I realized that that perpetual abbrev.tex is missing.
If pdflatex crashes immediately if it cannot find abbrev.tex then it will help me
to locate the source of the problem.
Is there a way to cause pdflatex to just die when it cannot find a file?
\InputIfFileExists{yourfile.tex}{}{\batchmode \read -1 to \x }– Phelype Oleinik Jul 21 '21 at 13:59\inputalready complains on a file not found, telling you the name of the guilty file, so you shouldn't need more than that to debug. The trick in my comment puts TeX in\batchmode(no terminal output and no user interaction), then\read -1 to \xtries to read something from the terminal; since user interaction is off, TeX exits immediately. But that gives you absolutely no clue on what file is missing! – Phelype Oleinik Jul 22 '21 at 00:11Errorand it will most likely take you to something that needs attention – Phelype Oleinik Jul 22 '21 at 02:42