Hi All,
I trying to write build.xml file for Automatic build and deploy.
All my IS servers, Deployer, ABE, Jenkins is on Linux.
My build.xml looks as below.
When I run the Jenkins, it throws below error. It could be because of syntax [if-else] in build.xml
This script works on windows, if I need to place this build.xml running on linux what could be the replacement.
Please suggest.
<target name="build" depends="initLog">
<echo message="${ant.version}"/>
<antversion property="ant-is-atleast-8" atleast="1.8" />
<if>
<isset property="ant-is-atleast-8" />
<then>
<property name="env.JAVA_MAX_MEM" value="256M"/>
<property name="max.mem" value="-Xmx${env.JAVA_MAX_MEM}"/>
<property name="env.JAVA_MAX_PERM_SIZE" value="128M"/>
<property name="max.perm.size" value="-XX:MaxPermSize=${env.JAVA_MAX_PERM_SIZE}"/>
<antfetch target="createNewBuildNumber" return="build.number"/>
<if>
<equals arg1="${enable.checkout}" arg2="true"/>
<then>
<echo message="Started Checkout task............." />
<antcall target="CheckOut"/>
<echo message="Checkout task complete............." />
</then>
</if>
<antcall target="createOutputDir" />
<if>
<equals arg1="${enable.build.IS}" arg2="true"/>
<then>
<echo message="Started Integration Server Build............." />
<antcall target="buildIS">
<param name="build.version" value="${build.number}"/>
</antcall>
<echo message="Integration Server Build complete..........." />
</then>
</if>
<antcall target="createIndex"/>
<if>
<equals arg1="${enable.archive}" arg2="true"/>
<then>
<echo message="Archiving the build.............${build.number}" />
<antcall target="archive"/>
</then>
</if>
</then>
<else>
<echo message="Incorrect version of ant is being used. Please use version 1.8.2 or more."/>
<echo message="Version of ant being used is : ${ant.version}"/>
</else>
</if>
</target>