While working on a somewhat larger scale document I always end up with numerous prints, .dvis, .pdfs and so on and so forth. Once, I lost all my original .tex documents and thus had to copy everything from a pdf and reformat it. In a case like that, it sure is handy to know exactly with which version you are dealing and which one is the latest. So for my thesis I wanted to add a little automatic timestamp to each print. Sure enough I found timestamp.sty. Just go to your local package repository, create a folder called <timestamp> and save timestamp.sty into it. With
in the preambel and
anywhere in your document, you can then add the – you’re guessing it – timestamp. The output will look like this:
Now, I never liked this date format, so if you, too, prefer DD-MM-YYYY, open timestamp.sty and scroll to the very bottom. Replace
\ifnum\month<10 0\fi\the\month-%
\ifnum\day<10 0\fi\the\day\ \xxivtime}
(the last three lines above \endinput) with
\ifnum\month<10 0\fi\the\month.\,%
\the\year\ — \xxivtime\,h}
\timestamp then produces
However, the version I use looks like this:
\ifnum\month<10 0\fi\the\month.\,%
\the\year\ at \xxivtime\,h}
So the output reads
Dominik Wujastyk
Thanks, this is very handy! You should put it into CTAN.
Best,
Dominik
Jan
Thanks Dominik, glad you find it useful. As for CTAN, Timestamp is already in there, and I feel merely changing the output format is not adding enough to justify a new packet. Take care!