From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/5045 Path: main.gmane.org!not-for-mail From: Hartmut Henkel Newsgroups: gmane.comp.tex.context Subject: Re: Versionnumbers Date: Wed, 11 Jul 2001 23:03:15 +0200 (CEST) Sender: owner-ntg-context@let.uu.nl Message-ID: References: <009a01c10958$c6640420$a7a5e0d5@pandora.be> NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: main.gmane.org 1035395664 30811 80.91.224.250 (23 Oct 2002 17:54:24 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 23 Oct 2002 17:54:24 +0000 (UTC) Cc: ntg-context Original-To: Frans Goddijn In-Reply-To: <009a01c10958$c6640420$a7a5e0d5@pandora.be> Xref: main.gmane.org gmane.comp.tex.context:5045 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:5045 You might use `rcs', revision control system. This stamps your files with an Id string, containing filename, -version, -date, creator... You submit e. g. the file foo.tex by ci foo.tex. You get the new version for editing by typing co -l foo.tex In plain TeX the following macro scans the Id string, when you have initially included a line \scanrcs $Id$ into your input file: % begin of file foo.tex \def\scanrcs $#1 #2,v #3 #4/#5/#6 #7 #8 #9 ${% \def\fileversion{#3} \def\filedate{#4#5#6} % Or whatever date format you like } \scanrcs $Id: foo.tex,v 1.1 2001/07/11 20:49:46 hahe Exp hahe $ \fileversion \bye % end of file foo.tex E. g. this prints `1.1', the current version. Should be transferable also to ConTeXt, but don't have experience with it. Have fun! Hartmut On Tue, 10 Jul 2001, Frans Goddijn wrote: > I think a current-date/time/seconds line in basic TeX code would > do that unless you compile several times per second ;-))) > > I'm trying to keep track of the versions of my documents. Is it > possible to print the number of times a file has been generated in a > title or a header? > Or, is there some other way to generate versionnumbers? ------------------------------------------------------------------------ Dr.-Ing. Hartmut Henkel In den Auwiesen 6, D-68723 Oftersheim, Germany E-Mail: hartmut_henkel@gmx.de http://www.circuitwizard.de ------------------------------------------------------------------------