incubator-flex-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Justin Mclean <jus...@classsoftware.com>
Subject Re: [CODE] Short cleanup
Date Fri, 24 Feb 2012 22:11:08 GMT
Hi,

ANT can do this quite easily.

If we change all Version.as files to be like so:
mx_internal static const VERSION:String = "@release@";

Then this target will inject the version number into all Version.as files:
<target name="setFlexSDKVersion">
	<replace dir="${basedir}" includes="**/Version.as" token="@release@" value="${release.version}.${build.number}"
/>
</target>

We have these currently in the build file:
<property name="release.version" value="4.6.0"/>    
<property name="build.number" value="0"/> 

So that would replace every occurrence of "@release@" with "4.6.0.0".

Minor issue with this is that now the Version.as files are out of sync with SVN, could accidentally
be checked back in with wrong version numbers or the like. 

I guess there's the more philosophical  question of do we really want ANT scripts that modify
the source code?

Justin 




Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message