db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel John Debrunner <...@debrunners.com>
Subject Re: version scheme
Date Fri, 03 Sep 2004 18:54:42 GMT
Hash: SHA1

Jan Hlavatý wrote:

| Daniel John Debrunner wrote:
|>Does anyone know of any neat tricks to get the subversion global
|>revision number into an ant task?
|>To get the SVN number into the built jars as the build number, a script
|>something like this is needed
|>SVN_CHANGE=`some way to get revision number out of SVN`
|>ant -Dchangenumber=$SVN_CHANGE buildjars
| You could try to run "svn info" in the root of the working copy and
parse the output,
| looking for a line starting with "Revision:".
| But do it in Java, or it wont be portable ;)

Thanks to the wonders of Google I found that the SVN command
svnversion gives a single value intended to be used as a build number.
It's even better in that it appends an M if the code has modified
versions. Derby code would need to be changed a little to handle the
build number as a string and not a number. I think the build number is
only used for display, so changing to a string should not be tricky.

Then we need an ant way of executing svnversion and setting
changenumber, this is in top level build.xml file.


Version: GnuPG v1.2.5 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org


View raw message