|
From: <mba...@us...> - 2007-02-18 11:37:56
|
Revision: 1958
http://svn.sourceforge.net/rubyeclipse/?rev=1958&view=rev
Author: mbarchfe
Date: 2007-02-18 03:37:55 -0800 (Sun, 18 Feb 2007)
Log Message:
-----------
tidying up, added rdt specfic postBuild
Modified Paths:
--------------
trunk/org.rubypeople.rdt.pluginbuilder/build-files/customTargets.xml
trunk/org.rubypeople.rdt.pluginbuilder/build.xml
Added Paths:
-----------
trunk/org.rubypeople.rdt.pluginbuilder/build-files/postBuild.xml
Removed Paths:
-------------
trunk/org.rubypeople.rdt.pluginbuilder/build-cc.xml
Deleted: trunk/org.rubypeople.rdt.pluginbuilder/build-cc.xml
===================================================================
Modified: trunk/org.rubypeople.rdt.pluginbuilder/build-files/customTargets.xml
===================================================================
--- trunk/org.rubypeople.rdt.pluginbuilder/build-files/customTargets.xml 2007-02-17 22:03:25 UTC (rev 1957)
+++ trunk/org.rubypeople.rdt.pluginbuilder/build-files/customTargets.xml 2007-02-18 11:37:55 UTC (rev 1958)
@@ -141,22 +141,24 @@
<target name="postBuild" depends="-prepareBuildResultsDirectory">
<antcall target="runTests"/>
<antcall target="package"/>
+ <condition property="is.External.Postbuild">
+ <available file="${buildHome}/build-files/postBuild.xml"/>
+ </condition>
+ <antcall target="callExternalPostBuild"/>
</target>
<!-- ===================================================================== -->
<!-- Run tests. -->
<!-- ===================================================================== -->
<property name="buildResultsDirectory" value="${buildDirectory}/results" />
<target name="runTests" if="isRunTests">
- <property name="automatedTestsHome" location="${buildHome}/build-files/automatedTests"/>
+ <property name="automatedTestsHome" location="${buildHome}/build-files/automatedTests"/>
<ant antfile="${automatedTestsHome}/run-tests.xml" target="run" dir="${automatedTestsHome}">
<property name="test.result.dir" value="${buildResultsDirectory}/testresults"/>
- <!-- important inherited properties: testResultDir and cobertura.result.dir -->
</ant>
-
- </target>
+ </target>
<!--======================================================-->
- <!-- Preparing build results -->
+ <!-- Gather build results -->
<!-- ==================================================== -->
<target name="-prepareBuildResultsDirectory">
<echo message="Creating ${buildResultsDirectory}" />
@@ -164,13 +166,18 @@
</target>
<target name="package">
<copy todir="${buildResultsDirectory}" flatten="true">
- <fileset dir="${buildDirectory}/${buildLabel}">
- <include name="*.zip" />
- </fileset>
+ <fileset dir="${buildDirectory}" includes="${buildType}-**/*.zip" />
</copy>
</target>
+ <!--======================================================-->
+ <!-- Call External post build file if available -->
+ <!-- ==================================================== -->
+ <target name="callExternalPostBuild" if="is.External.Postbuild">
+ <ant antfile="${buildHome}/build-files/postBuild.xml"/>
+ </target>
+
<target name="noDefault">
<echo message="You must specify a target when invoking this file" />
</target>
-</project>
+</project>
\ No newline at end of file
Added: trunk/org.rubypeople.rdt.pluginbuilder/build-files/postBuild.xml
===================================================================
--- trunk/org.rubypeople.rdt.pluginbuilder/build-files/postBuild.xml (rev 0)
+++ trunk/org.rubypeople.rdt.pluginbuilder/build-files/postBuild.xml 2007-02-18 11:37:55 UTC (rev 1958)
@@ -0,0 +1,76 @@
+<project name="Run as part of postBuild" default="main">
+
+ <target name="main">
+ <property name="UpdateSiteStagingLocation" value="${buildResultsDirectory}/updateSite"/>
+ <antcall target="-generateUpdateSite"/>
+ <antcall target="-gatherFiles"/>
+ </target>
+
+ <!--======================================================-->
+ <!-- UpdateSite Export target, to be called from allElements -->
+ <!-- ==================================================== -->
+ <target name="updateSiteExport">
+ <ant antfile="build.xml" dir="${buildDirectory}/features/${id}/" target="build.update.jar">
+ <property name="feature.destination" value="${UpdateSiteStagingLocation}/features"/>
+ <property name="plugin.destination" value="${UpdateSiteStagingLocation}/plugins"/>
+ </ant>
+ </target>
+
+ <target name="-generateUpdateSite">
+ <!-- Create the directory structure -->
+ <mkdir dir="${UpdateSiteStagingLocation}"/>
+ <mkdir dir="${UpdateSiteStagingLocation}/features"/>
+ <mkdir dir="${UpdateSiteStagingLocation}/plugins"/>
+ <!-- Build the jar files -->
+ <ant antfile="${builder}/customTargets.xml" target="allElements">
+ <property name="genericTargets" value="${builder}/postBuild.xml"/>
+ <property name="target" value="updateSiteExport"/>
+ </ant>
+ <!-- site.xml files for integration and release builds are handled elsewhere -->
+ <antcall target="-createNightlyBuildSiteXml"/>
+ <delete dir="${buildDirectory}/temp.updatesite"/>
+ </target>
+
+ <target name="-createNightlyBuildSiteXml" if="isNightlyBuild">
+ <echo file="${UpdateSiteStagingLocation}/site.xml"><?xml
+ version="1.0" encoding="UTF-8"?>
+ <site> <description> The Ruby Development Tools nightly
+ builds. </description> <feature
+ url="features/org.rubypeople.rdt_${version.full}.jar"
+ id="org.rubypeople.rdt"
+ version="${version.full}"> <category
+ name="RubyEclipseNightlyBuilds"/> </feature>
+ <category-def name="RubyEclipseNightlyBuilds"
+ label="RDT Nightly Builds"> </category-def>
+ </site> </echo>
+ </target>
+
+ <target name="-gatherFiles">
+ <mkdir dir="${buildResultsDirectory}/logs"/>
+
+ <copy todir="${buildResultsDirectory}/logs" flatten="true">
+ <fileset dir="${buildDirectory}">
+ <include name="**/*.log"/>
+ </fileset>
+ </copy>
+ <copy todir="${buildResultsDirectory}" flatten="true">
+ <fileset dir="${buildDirectory}">
+ <include name="**/Changelog.txt"/>
+ </fileset>
+ </copy>
+
+ <!--<copy file="${buildDirectory}/workspace-rdt-tests/.metadata/.log"
+ tofile="${buildResultsDirectory}/logs/testsWorkspace.log" failonerror="false"/>
+ -->
+
+ <!--
+ <mkdir dir="${buildResultsDirectory}/doc"/>
+ <copy todir="${buildResultsDirectory}/doc">
+ <fileset dir="${buildDirectory}/plugins/org.rubypeople.rdt.doc.user">
+ <include name="html/**/*"/>
+ <include name="images/**/*"/>
+ </fileset>
+ </copy>
+ -->
+ </target>
+</project>
Modified: trunk/org.rubypeople.rdt.pluginbuilder/build.xml
===================================================================
--- trunk/org.rubypeople.rdt.pluginbuilder/build.xml 2007-02-17 22:03:25 UTC (rev 1957)
+++ trunk/org.rubypeople.rdt.pluginbuilder/build.xml 2007-02-18 11:37:55 UTC (rev 1958)
@@ -28,19 +28,21 @@
<fileset dir="${eclipseDir}/plugins" includes="org.eclipse.pde.build_*/scripts/build.xml" id="pde.plugin.path" />
<pathconvert property="buildfile" refid="pde.plugin.path" />
<fail message="Could not find org.eclipse.pde.build_*/scripts/build.xml in ${eclipseDir}/plugins. PDE not installed?" unless="buildfile"/>
- <condition property="is.buildTarget.main.or.fetch">
+
+ <!-- set defaults -->
+ <property name="buildTarget" value="main"/>
+ <property name="verboseAnt" value="-Ddummy=true"/>
+
+ <!-- check if clean should be called -->
+ <condition property="is.clean">
<or>
<equals arg1="main" arg2="${buildTarget}" trim="true"/>
<equals arg1="fetch" arg2="${buildTarget}" trim="true"/>
</or>
</condition>
-
- <!-- set defaults -->
- <property name="buildTarget" value="main"/>
- <property name="verboseAnt" value="-Ddummy=true"/>
</target>
- <target name="-clean" if="is.buildTarget.main.or.fetch">
+ <target name="-clean" if="is.clean">
<echo level="info" message="Cleaning directory ${buildDirectory}"/>
<delete dir="${buildDirectory}" verbose="false"/>
<mkdir dir="${buildDirectory}"/>
@@ -82,10 +84,10 @@
</java>
</target>
- <target name="dist-cc"
+ <target name="main-cc"
description="This target is suited to be run from cruisecontrol. The property 'label' is expected to be set from cruisecontrol.">
<property name="version.full" value="${label}"/>
- <!-- TODO: extract qualifier from label -->
+ <!-- TODO: extract qualifier correctly from label -->
<property name="version.qualifier" value="${label}"/>
<antcall target="-build"/>
</target>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|