I've just run into a problem with mVersion and by extension latexmk. As users of mVersion know, it updates a file version.dat with each run of the pdf/xe/lua/whatever engine. Until I reached the point where I've added the indices and bibliography that was fine. Now however I'm looking at version.dat being changed three times in a single run (minimum of 3). That sadly puts latexmk in a loop and it errors out with:
Latexmk: applying rule 'pdflatex'...
Rule 'pdflatex': File changes, etc:
Changed files, or newly in use since previous run(s):
'version.dat'
Latexmk: Maximum runs of pdflatex reached without getting stable files
Latexmk: All targets (Jourdan.pdf) are up-to-date
Latexmk: Did not finish processing file 'Jourdan':
'pdflatex' needed too many passes
Latexmk: Use the -f option to force complete processing,
unless error was exceeding maximum runs of latex/pdflatex.
Since I suspect I'm hardly the first to run into this problem, I'm looking to the forum for advice. I'm right now working through the 34-page manual in order to find how to add in my own post-processing (after the first run) Perl script. I'm guessing that creation of a latexmkrc file is part of the solution to several problems here, but I'm a bit out to sea at the moment regarding a solution.
Of course I can resort to a batch file (I'm running under Windows 7) and I will if I have to, but I'm hoping that I can get a leg up on a hardwired solution with latexmk.
tl;dr --- how do I stop shooting myself in the foot with mVersion. The side problem of running a Perl script in mid-stream I'll handle myself.