4 ms·
On Linux, I do the following: while inotifywait *.tex; do sleep 0.2 && pdflatex main.tex && killall -HUP mupdf; done This will, when a .tex file is written,
by majewsky 10y ago
On Linux, I do the following:
while inotifywait *.tex; do sleep 0.2 && pdflatex main.tex && killall -HUP mupdf; done
This will, when a .tex file is written, wait a moment until all disk IO is done, then run pdflatex and trigger a reload in my PDF viewer (some also do that automatically when the .pdf file is changed).
The only annoyance is that big .tex files (esp. Beamer presentations) may take long to compile, which interrupts the flow. But in that case, it helps to distribute the sources into multiple files and to comment out the source files that are not needed at the moment.
- lucb1e 10y agoinotifywait is fantastic, used it lots of times. Good idea to use it for TeX too!