Author: nickboldt
Date: 2011-11-02 18:20:57 -0400 (Wed, 02 Nov 2011)
New Revision: 36146
Modified:
trunk/build/aggregate/site/build.xml
Log:
less unzip/zip, more targets
Modified: trunk/build/aggregate/site/build.xml
===================================================================
--- trunk/build/aggregate/site/build.xml 2011-11-02 22:20:50 UTC (rev 36145)
+++ trunk/build/aggregate/site/build.xml 2011-11-02 22:20:57 UTC (rev 36146)
@@ -31,7 +31,7 @@
<property name="aggregateSite.properties"
value="aggregateSite.jbosstools.properties" />
<property file="${aggregateSite.properties}" />
- <property name="web.content.files" value="index.html, **/*.css,
README*, *directory.xml"/>
+ <property name="web.content.files" value="index.html, **/*.css,
README*, *directory.xml" />
<target name="init">
<ant antfile="${build.xml}" target="init" />
@@ -45,7 +45,7 @@
<antcall target="get.saxon" />
</target>
- <target name="custom.build" description="aggregate update site
extras"
depends="init,check.target,add.associate.sites,add.web.content,pack.zip,collect.zips,collect.metadata,create.summary.file"
/>
+ <target name="custom.build" description="aggregate update site
extras"
depends="init,check.target,unpack.content.jar,add.associate.sites,add.web.content,pack.content.jar,pack.zip,collect.zips,collect.metadata,create.summary.file"
/>
<target name="get.saxon" unless="saxon.jar.exists">
<!-- or use
http://downloads.sourceforge.net/saxon/saxonhe9-3-0-4j.zip ? -->
@@ -351,13 +351,6 @@
</not>
</and>
<then>
- <if>
- <available file="${update.site.source.dir}/content.jar"
type="file" />
- <then>
- <unzip src="${update.site.source.dir}/content.jar"
dest="${update.site.source.dir}" />
- <delete file="${update.site.source.dir}/content.jar" />
- </then>
- </if>
<!-- counter variable -->
<var name="associate.sites.0" value="" />
<for param="associate.site" list="${associate.sites}"
delimiter=",
@@ -390,13 +383,26 @@
</echo>
<copy file="${update.site.source.dir}/content.xml"
tofile="${update.site.source.dir}/content.old.xml" overwrite="true"
/>
<xslt style="remove-uncategorized.xsl"
in="${update.site.source.dir}/content.old.xml"
out="${update.site.source.dir}/content.xml" />
- <zip destfile="${update.site.source.dir}/content.jar"
basedir="${update.site.source.dir}" includes="content.xml" />
- <delete file="${update.site.source.dir}/content.xml" />
- <delete file="${update.site.source.dir}/content.old.xml" />
</then>
</if>
</target>
+ <target name="unpack.content.jar">
+ <if>
+ <available file="${update.site.source.dir}/content.jar"
type="file" />
+ <then>
+ <unzip src="${update.site.source.dir}/content.jar"
dest="${update.site.source.dir}" />
+ <delete file="${update.site.source.dir}/content.jar" />
+ </then>
+ </if>
+ </target>
+
+ <target name="pack.content.jar">
+ <zip destfile="${update.site.source.dir}/content.jar"
basedir="${update.site.source.dir}" includes="content.xml" />
+ <delete file="${update.site.source.dir}/content.xml" />
+ <delete file="${update.site.source.dir}/content.old.xml" />
+ </target>
+
<target name="unpack.zip">
<unzip src="${output.dir}/target/site_assembly.zip"
dest="${update.site.source.dir}" />
</target>
@@ -479,12 +485,12 @@
<!-- get filename matching
org.jboss.tools.central.discovery_1.0.0.v20111013-0511-M4.jar, then generate replacement
directory.xml file -->
<path id="central.discovery.jar.id">
- <fileset dir="${update.site.source.dir}/plugins">
- <include name="org.jboss.tools.central.discovery_*.jar"/>
- </fileset>
+ <fileset dir="${update.site.source.dir}/plugins">
+ <include name="org.jboss.tools.central.discovery_*.jar" />
+ </fileset>
</path>
- <property name="central.discovery.path"
refid="central.discovery.jar.id"/>
- <basename property="central.discovery.jar"
file="${central.discovery.path}"/>
+ <property name="central.discovery.path"
refid="central.discovery.jar.id" />
+ <basename property="central.discovery.jar"
file="${central.discovery.path}" />
<echo file="${output.dir}/jbosstools-directory.xml"><?xml
version='1.0' encoding='UTF-8'?>
<directory
xmlns="http://www.eclipse.org/mylyn/discovery/directory/">
<entry url="plugins/${central.discovery.jar}"
permitCategories="true"/>
@@ -593,7 +599,7 @@
<target name="collect.metadata" description="collect svn revision info
+ other metadata (JOB_NAME, BUILD_ID, BUILD_NUMBER, WORKSPACE, HUDSON_SLAVE), zip file
names+sizes+md5sums">
<property name="aggregate.zips.dir" value="${output.dir}/zips"
/>
- <mkdir dir="${aggregate.zips.dir}"/>
+ <mkdir dir="${aggregate.zips.dir}" />
<!-- load file properties (name, size, md5sum) -->
<if>
<available file="${aggregate.zips.dir}/build.properties.file.txt"
type="file" />