Hi Nicolas,
how about controlling the version number in the build?
<property name="version" value="XX.YY.ZZ"/>
then update the version in the source file on every build:
<replaceregexp file="${source}/some/package/Class.java">
<regexp pattern="public final static String version = (.*)" />
<substitution expression='public final static String version =
"${version}";' />
</replaceregexp>
and then compile and use ${version} to name the jar?
Barry
Nicolas Vervelle wrote:
Hi,
In one of my Java source file, I have a line like this:
public final static String version = "XX.YY.ZZ";
I'd like to extract the XX.YY.ZZ from the Ant build to name the
resulting jar file with it : Jmol.XX.YY.ZZ.jar
Can someone help me with how to extract the string from the file ?
Thanks in advance,
Nicolas
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]