Skip to content

Instantly share code, notes, and snippets.

@xian xian/gist:730793
Created Dec 6, 2010

Embed
What would you like to do?
Android: include build number and date
<property environment="env"/>
<condition property="build.number" value="${env.BUILD_NUMBER}" else="unknown">
<isset property="env.BUILD_NUMBER"/>
</condition>
<exec command="date" outputproperty="build.date"/>
<target name="update-buildinfo">
<echo>updating build number and date to ${build.number} and ${build.date}</echo>
<echo file="res/values/buildinfo.xml"
>&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;resources&gt;
&lt;string name="build_number"&gt;${build.number}&lt;/string&gt;
&lt;string name="build_date"&gt;${build.date}&lt;/string&gt;
&lt;/resources&gt;
</echo>
</target>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.