texdiff (1) Linux Manual Page
NAME
texdiff – Compares two (La)TeX documents to create a merged version showing changes, similar to that of ‘Change Tracking’ in some word processors.
SYNOPSIS
texdiff [–nofloats|-n] old.tex new.tex [diff.tex]
DESCRIPTION
The first two files are compared and a new TeX file is output. When the output file is processed with (La)TeX it marks new changes with blue and old text with red with a strike-through line. Furthermore, passages with changes are marked at the margin with grey bars by the LaTeX "changebar" package (although only after running "dvips", in "xdvi" the bars are one inch too far left to compensate the one inch offset inserted by TeX printer drivers).
"texdiff" uses and therefore requires the "wdiff" command to insert these marks. If LaTeX macros are included in those striked out or underlined passages, the latex run will most likely fail. The source of most problems lies in "wdiff" tearing apart pairs of braces. Therefore "texdiff" is a perl script that calls "wdiff" internally and fixes "wdiff"‘s output by re-pairing braces again and handling some commonly used LaTeX macros.
For texdiff to work, the following LaTeX code must be inserted in the preamble of the LaTeX document:
