Support for removing "TrackChanges" commands

Author: williamjsdavisCreated Feb 5, 2025Updated Feb 5, 2025

"TrackChanges" (https://trackchanges.sourceforge.net/) is a popular package for collaboratively editing LaTeX documents. Personally, I've had many papers where I have used it to add comments directly into a .tex file. I've used it as a reviewer, and I've had papers returned to me with TrackChanges comments in them. TrackChanges supports the following commands:

  • \note[editor]{The note}
  • \annote[editor]{Text to annotate}{The note}
  • \add[editor]{Text to add}
  • \remove[editor]{Text to remove}
  • \change[editor]{Text to remove}{Text to add}

When submitting a manuscript, I've found it desirable to remove all the TrackChanges commands from the .tex file. This includes:

  1. Removing notes and remove commands;
  2. Replacing the \add command with the text specified in the curly brackets; and
  3. Replacing the \change command the the text in the second set of curly brackets.

Previously, I wrote a python package to remove these commends from a .tex file (https://github.com/williamjsdavis/UntrackChanges).

If people think it would be a helpful contribution, I can make a PR here to a built-in capability to remove TrackChanges commands.

Of course, one could just write regex replacements for these commands in the cleaner_config.yaml, but since TrackChanges is a common enough package perhaps it's worth providing built-in support for these replacements.

What do people think? Would this contribution be worthwhile?

Source: google-research/arxiv-latex-cleaner