[Dev-luatex] platform specific functionality

T T t34www at googlemail.com
Mon Mar 15 12:52:18 CET 2010

On 15 March 2010 07:47, Taco Hoekwater <taco at elvenkind.com> wrote:
> T T wrote:
>> I would also suggest to remove the 'svn up' from the script. While
>> working on/testing local changes you do not necessarily want to keep
>> the working copy in sync with the head. And perhaps
> Perhaps the call to getluatexsvnversion.sh should be an explicit
> option for build.sh instead of implied, but I prefer the rev. number
> to reflect the actual state of the repository, so I would like to
> leave the svn up command in it.

This is just a suggestion, but I think that the decision whether to
svn up or not should be configurable somehow. There might be justified
reasons why one doesn't want to do that (e.g. svn doesn't work for me
here because of proxy -- every time it stalls until timeout making it
quite annoying).

>> luatex_svnversion.h could be created/updated only when the revision
>> number actually changes rather than every time (i.e. read the old
> Probably. As I wrote above, I am not that good in shell either,
> and the generated header is not in the repository so I don't think
> it matters a whole lot, but if someone writes a patch I will apply it.

OK, here we go:

#! /bin/sh

# This script should be run within the source directory.



if [ ! -r $FILE ]
 echo '#define luatex_svn_revision -1' > $FILE
if ( [ -d ./.svn ] && svnversion > /dev/null )
  # svn up > /dev/null
  DEFREV=`cat $FILE`
  SVNREV=`svnversion -c . | sed -ne 's/^[0-9]*:*\([0-9]*\).*/#define
luatex_svn_revision \1/p'`
  test "$DEFREV" != "$SVNREV" && echo "$SVNREV" > $FILE



More information about the dev-luatex mailing list