From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/38753 Path: news.gmane.org!not-for-mail From: Robin Kirkham Newsgroups: gmane.comp.tex.context Subject: Re: Module for svn info Date: Tue, 22 Jan 2008 10:58:11 +1100 Message-ID: <4D2077CD-619C-4429-A1D7-733931A9FB5C@csiro.au> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v915) Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1200959963 4954 80.91.229.12 (21 Jan 2008 23:59:23 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 21 Jan 2008 23:59:23 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Tue Jan 22 00:59:42 2008 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by lo.gmane.org with esmtp (Exim 4.50) id 1JH6Y9-00013T-7R for gctc-ntg-context-518@m.gmane.org; Tue, 22 Jan 2008 00:59:33 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 87E351FC18; Tue, 22 Jan 2008 00:58:52 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 14071-03-2; Tue, 22 Jan 2008 00:58:38 +0100 (CET) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 794BD1FC16; Tue, 22 Jan 2008 00:58:38 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 837501FC0B for ; Tue, 22 Jan 2008 00:58:31 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 17270-01 for ; Tue, 22 Jan 2008 00:58:21 +0100 (CET) Original-Received: from vic-MTAout4.csiro.au (vic-MTAout4.csiro.au [150.229.64.41]) by ronja.ntg.nl (Postfix) with ESMTP id 5CC471FBC6 for ; Tue, 22 Jan 2008 00:58:16 +0100 (CET) X-IronPort-AV: E=Sophos;i="4.25,229,1199624400"; d="scan'208";a="156158435" Original-Received: from exgw1-mel.nexus.csiro.au ([138.194.3.56]) by vic-ironport-int.csiro.au with ESMTP; 22 Jan 2008 10:58:12 +1100 Original-Received: from kir092m.clayton.csiro.au ([138.194.25.80]) by exgw1-mel.nexus.csiro.au with Microsoft SMTPSVC(5.0.2195.6713); Tue, 22 Jan 2008 10:58:12 +1100 X-Mailer: Apple Mail (2.915) X-OriginalArrivalTime: 21 Jan 2008 23:58:12.0115 (UTC) FILETIME=[7AD58E30:01C85C89] X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.9 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:38753 Archived-At: Hi Markus, If your sources are in svn, then they actually have the same svn- number, after a commit. But the numbers in the $Revision$ or $Id$ tags of your working copies are not updated by svn commit. However, if you do an "svn update" after the commit, it should update the numbers. So, you shouldn't need to work out the maximum value. Here, we actually use the output of the "svnversion" command, save it automatically it in a file, and include it in the document. This way, the version number indicates if the document came from checked-in sources, modified sources, or mixed revisions. We don't have a module to do it, just a svnversion > svnversion.tex ; texexec document.tex in the Makefile, and on the document front page somewhere \doiffileelse{svnversion.tex}{ Subversion revision \ignorespaces \input svnversion\relax \removeunwantedspaces . \crlf }{} Cheers, Robin > Hi Aditya, > > thanks for your reply. It's a good starting point. > > One thing is missing in this solution. > > Our documents are structured into several files. > Every file has an svn-version. So I want to > calculate the max version. > > Do you know a small example where a max value > is calculated. I would try to integrate it into > the other example. > > Kind regards, > Markus ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________