I am attempting to update two manifest files from existing jar and war.
The goal of my ant task is to update their manifest file and jar the parent
folder.
This is what my task looks like:
<target name="copy-files">
<echo>********************************************************************</echo>
<echo>Copying the binaries to configured destination.</echo>
<copy todir="${env.deploy.path}-${env.repos.revision}">
<fileset
dir="${env.source.path}/Optimizer/deploy"/>
</copy>
<tstamp/>
<jar
destfile="${env.repos.username}-${DSTAMP}${TSTAMP}-${env.repos.revision}.zip"
basedir="${env.deploy.path}-${env.repos.revision}">
<manifest>
<attribute name="Built-By"
value="${env.repos.username}"/>
<attribute name="Built-Date"
value="${DSTAMP}${TSTAMP}"/>
<attribute name="Repository"
value="${env.repos.url}"/>
<attribute name="Revision"
value="${env.repos.revision}"/>
</manifest>
<manifest
file="${env.deploy.path}-${env.repos.revision}/local/comact_Optimizer_main.jar
" mode="update">
<attribute name="Built-By"
value="${env.repos.username}"/>
<attribute name="Built-Date"
value="${DSTAMP}${TSTAMP}"/>
<attribute name="Repository"
value="${env.repos.url}"/>
<attribute name="Revision"
value="${env.repos.revision}"/>
</manifest>
<!--manifest
file="${env.deploy.path}-${env.repos.revision}/web/EdgExpert.war" mode="update">
<attribute name="Built-By"
value="${env.repos.username}"/>
<attribute name="Built-Date"
value="${DSTAMP}${TSTAMP}"/>
<attribute name="Repository"
value="${env.repos.url}"/>
<attribute name="Revision"
value="${env.repos.revision}"/>
</manifest-->
</jar>
<echo>[DONE]</echo>
<echo>********************************************************************</echo>
</target>
The copy is executed without any problem, right after the copy. The build quits
without any error, and manifest aren't updated. If I comment the two last
manifest call, everything gets executed without any problem.
I tried reading the doc to find "update" samples, but didn't find any.
Or maybe the manifest calls aren't done at the right place ?
Something important to know is that this script is not the one building the jar
and war files.
Thanks for your help,
Pascal