|
From: Markus B. <mba...@us...> - 2005-03-27 11:32:47
|
Update of /cvsroot/rubyeclipse/org.rubypeople.rdt.build/bootstrap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2479/bootstrap Modified Files: customTargets.xml Log Message: added updatesite and dynamic versioning for nightly build, formatted Index: customTargets.xml =================================================================== RCS file: /cvsroot/rubyeclipse/org.rubypeople.rdt.build/bootstrap/customTargets.xml,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** customTargets.xml 26 Mar 2005 06:42:40 -0000 1.6 --- customTargets.xml 27 Mar 2005 11:32:38 -0000 1.7 *************** *** 1,229 **** <project name="Build specific targets and properties" default="noDefault" > ! ! <!-- ===================================================================== --> ! <!-- Run a given ${target} on all elements being built --> ! <!-- Add on <ant> task for each top level element being built. --> ! <!-- ===================================================================== --> ! <target name="allElements"> ! ! <ant antfile="${genericTargets}" target="${target}" > ! <property name="type" value="feature" /> ! <property name="id" value="org.rubypeople.rdt" /> ! </ant> ! ! <ant antfile="${genericTargets}" target="${target}" > ! <property name="type" value="feature" /> ! <property name="id" value="org.rubypeople.rdt-tests" /> ! </ant> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Targets to assemble the built elements for particular configurations --> ! <!-- These generally call the generated assemble scripts (named in --> ! <!-- ${assembleScriptName}) but may also add pre and post processing --> ! <!-- Add one target for each root element and each configuration --> ! <!-- ===================================================================== --> ! ! <target name="assemble.org.rubypeople.rdt"> ! <ant antfile="${assembleScriptName}" dir="${buildDirectory}"> ! <property name="zipargs" value="" /> ! </ant> ! </target> ! ! <target name="assemble.org.rubypeople.rdt-tests"> ! <ant antfile="${assembleScriptName}" dir="${buildDirectory}"> ! <property name="zipargs" value="" /> ! </ant> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Check out map files from correct repository --> ! <!-- Replace values for cvsRoot, package and mapVersionTag as desired. --> ! <!-- ===================================================================== --> ! <target name="getMapFiles"> ! <property name="mapVersionTag" value="HEAD" /> ! <antcall target="getMapFilesWithExtMethod"/> ! <antcall target="getMapFilesWithPserverMethod"/> ! </target> ! ! <target name="getMapFilesWithExtMethod" unless="usePserver"> ! <property name="cvsRoot" value=":ext:cvs.sf.net:/cvsroot/rubyeclipse" /> ! <cvs ! cvsroot="${cvsRoot}" ! dest="${buildDirectory}/maps" ! command="export -r ${mapVersionTag} org.rubypeople.rdt.build/map" ! /> ! ! </target> ! ! <target name="getMapFilesWithPserverMethod" if="usePserver"> ! <property name="cvsRoot" value=":pserver:ano...@cv...:/cvsroot/rubyeclipse" /> ! <cvs ! cvsroot="${cvsRoot}" ! dest="${buildDirectory}/maps" ! command="export -r ${mapVersionTag} org.rubypeople.rdt.build/map" ! /> ! <replace dir="${buildDirectory}/maps" value=":pserver:anonymous@"> ! <include name="**/*.map"/> ! <replacetoken>:ext:</replacetoken> ! </replace> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do before setup --> ! <!-- ===================================================================== --> ! <target name="preSetup"> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do after setup but before starting the build proper --> ! <!-- ===================================================================== --> ! <target name="postSetup"> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do before fetching the build elements --> ! <!-- ===================================================================== --> ! <target name="preFetch"> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do after fetching the build elements --> ! <!-- ===================================================================== --> ! <target name="postFetch"> ! <replace file="${buildDirectory}/features/org.rubypeople.rdt/feature.xml"> ! <replacefilter token="CLOSE_XML_COMMENT" value="-->" /> ! <replacefilter token="START_XML_COMMENT" value="<!--" /> ! </replace> ! ! <replace file="${buildDirectory}/features/org.rubypeople.rdt/build.properties"> ! <replacefilter token="#generate.feature" value="generate.feature" /> ! </replace> ! ! <replace dir="${buildDirectory}/plugins"> ! <include name="org.rubypeople.rdt.*/plugin.xml"/> ! <replacefilter token="${featureVersion}" value="0.5.503260628" /> ! </replace> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do before generating the build scripts. --> ! <!-- ===================================================================== --> ! <target name="preGenerate"> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do after generating the build scripts. --> ! <!-- ===================================================================== --> ! <target name="postGenerate"> ! </target> ! ! ! <!-- ===================================================================== --> ! <!-- Steps to do before running the build.xmls for the elements being built. --> ! <!-- ===================================================================== --> ! <target name="preProcess"> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do after running the build.xmls for the elements being built. --> ! <!-- ===================================================================== --> ! <target name="postProcess"> ! </target> ! ! ! <!-- ===================================================================== --> ! <!-- Steps to do before running assemble. --> ! <!-- ===================================================================== --> ! <target name="preAssemble"> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do after running assemble. --> ! <!-- ===================================================================== --> ! <target name="postAssemble"> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do after the build is done. --> ! <!-- ===================================================================== --> ! <target name="postBuild"> ! <antcall target="test"/> ! <property name="UpdateSiteStagingLocation" value="${buildDirectory}/updateSite"/> ! <property name="sitePackagePrefix" value="org.rubypeople.updatesite"/> ! <antcall target="generateUpdateSite"/> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to test the build results --> ! <!-- ===================================================================== --> ! <target name="test" unless="dontRunTests"> ! <echo message="Setting up tests in ${eclipseAutomatedTestHome}"/> ! ! <copy file="${buildDirectory}/${buildLabel}/org.rubypeople.rdt-${buildId}.zip" tofile="${eclipseAutomatedTestHome}/eclipse-SDK-RDT-${buildId}.zip" /> ! <copy file="${buildDirectory}/${buildLabel}/org.rubypeople.rdt-tests-${buildId}.zip" tofile="${eclipseAutomatedTestHome}/eclipse-junit-tests-rdt-${buildId}.zip" /> ! ! <ant antfile="${eclipseAutomatedTestHome}/test.xml" target="runtests" dir="${eclipseAutomatedTestHome}"> ! <property name="os" value="${baseos}" /> ! <property name="ws" value="${basews}" /> ! <property name="arch" value="${basearch}" /> ! <property name="testPlugin" value="org.rubypeople.rdt.tests.all_0.5.0" /> ! <property name="report" value="org.rubypeople.rdt.tests.all" /> ! </ant> ! ! </target> ! ! <!--======================================================--> ! <!-- UpdateSite Export target --> ! <!-- ==================================================== --> ! <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 --> ! <antcall target="allElements"> ! <param name="genericTargets" value="${builder}/customTargets.xml"/> ! <param name="target" value="updateSiteExport"/> ! </antcall> ! ! <!-- Grab the rest of the site out of CVS --> ! <mkdir dir="${buildDirectory}/temp.updatesite"/> ! <property name="cvsRoot" value=":ext:cvs.sf.net:/cvsroot/rubyeclipse" /> ! ! <cvs cvsRoot="${cvsRoot}" ! package="${sitePackagePrefix}" ! dest="${buildDirectory}/temp.updatesite" ! tag="HEAD"/> ! ! <!-- Copy to staging area --> ! <copy todir="${UpdateSiteStagingLocation}"> ! <fileset file="${buildDirectory}/temp.updatesite/${sitePackagePrefix}/site.xml"/> ! </copy> ! ! <delete dir="${buildDirectory}/temp.updatesite"/> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Steps to do to publish the build results --> ! <!-- ===================================================================== --> ! <target name="publish"> ! </target> ! ! <!-- ===================================================================== --> ! <!-- Default target --> ! <!-- ===================================================================== --> ! <target name="noDefault"> ! <echo message="You must specify a target when invoking this file" /> ! </target> ! ! </project> --- 1,215 ---- <project name="Build specific targets and properties" default="noDefault" > ! <condition property="isNightlyBuild"> ! <equals arg1="${buildType}" arg2="N"/> ! </condition> ! <property file="${buildDirectory}/version.properties"/> ! <property name="buildLabel" value="${buildType}-${featureVersion}"/> ! <property name="buildId" value="${featureVersion}"/> ! <!-- ===================================================================== --> ! <!-- Run a given ${target} on all elements being built --> ! <!-- Add on <ant> task for each top level element being built. --> ! <!-- ===================================================================== --> ! <target name="allElements"> ! <ant antfile="${genericTargets}" target="${target}" > ! <property name="type" value="feature" /> ! <property name="id" value="org.rubypeople.rdt" /> ! </ant> ! <ant antfile="${genericTargets}" target="${target}" > ! <property name="type" value="feature" /> ! <property name="id" value="org.rubypeople.rdt-tests" /> ! </ant> ! </target> ! <!-- ===================================================================== --> ! <!-- Targets to assemble the built elements for particular configurations --> ! <!-- These generally call the generated assemble scripts (named in --> ! <!-- ${assembleScriptName}) but may also add pre and post processing --> ! <!-- Add one target for each root element and each configuration --> ! <!-- ===================================================================== --> ! <target name="assemble.org.rubypeople.rdt"> ! <ant antfile="${assembleScriptName}" dir="${buildDirectory}"> ! <property name="zipargs" value="" /> ! </ant> ! </target> ! <target name="assemble.org.rubypeople.rdt-tests"> ! <ant antfile="${assembleScriptName}" dir="${buildDirectory}"> ! <property name="zipargs" value="" /> ! </ant> ! </target> ! <!-- ===================================================================== --> ! <!-- Check out map files from correct repository --> ! <!-- Replace values for cvsRoot, package and mapVersionTag as desired. --> ! <!-- ===================================================================== --> ! <target name="getMapFiles"> ! <property name="mapVersionTag" value="HEAD" /> ! <antcall target="getMapFilesWithExtMethod"/> ! <antcall target="getMapFilesWithPserverMethod"/> ! </target> ! <target name="getMapFilesWithExtMethod" unless="usePserver"> ! <property name="cvsRoot" value=":ext:cvs.sf.net:/cvsroot/rubyeclipse" /> ! <cvs cvsroot="${cvsRoot}" dest="${buildDirectory}/maps" command="export -r ${mapVersionTag} org.rubypeople.rdt.build/map" /> ! </target> ! <target name="getMapFilesWithPserverMethod" if="usePserver"> ! <property name="cvsRoot" value=":pserver:ano...@cv...:/cvsroot/rubyeclipse" /> ! <cvs cvsroot="${cvsRoot}" dest="${buildDirectory}/maps" command="export -r ${mapVersionTag} org.rubypeople.rdt.build/map" /> ! <replace dir="${buildDirectory}/maps" value=":pserver:anonymous@"> ! <include name="**/*.map"/> ! <replacetoken>:ext:</replacetoken> ! </replace> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do before setup --> ! <!-- ===================================================================== --> ! <target name="preSetup" unless="featureVersion"> ! <tstamp> ! <!-- unfortunately one "y" in the pattern pads with 0, so 2005 will be displayed as 05 --> ! <format property="build.tstamp" pattern="5MMddhhmm"/> ! </tstamp> ! <condition property="featureVersion" value="${nightlyBuildFeatureVersionPrefix}${build.tstamp}"> ! <equals arg1="${buildType}" arg2="N"/> ! </condition> ! <fail unless="featureVersion" message="Property featureVersion must be set. Either directly or in case of a nightly build with nightlyBuildFeatureVersionPrefix."/> ! <echo message="Using featureVersion: ${featureVersion}."/> ! <echo file="${buildDirectory}/version.properties" message="featureVersion=${featureVersion}"/> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do after setup but before starting the build proper --> ! <!-- ===================================================================== --> ! <target name="postSetup"> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do before fetching the build elements --> ! <!-- ===================================================================== --> ! <target name="preFetch"> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do after fetching the build elements --> ! <!-- ===================================================================== --> ! <target name="postFetch"> ! <antcall target="replaceVersionsForNightlyBuild"/> ! <replace file="${buildDirectory}/features/org.rubypeople.rdt/feature.xml"> ! <replacefilter token="<!--@@INCLUDES@@-->" value="<includes id="org.rubypeople.rdt.source" version="${featureVersion}"/>"/> ! </replace> ! <replace file="${buildDirectory}/features/org.rubypeople.rdt/build.properties"> ! <replacefilter token="#generate.feature" value="generate.feature" /> ! </replace> ! </target> ! <target name="replaceVersionsForNightlyBuild" if="baseFeatureVersion"> ! <replace dir="${buildDirectory}/features"> ! <include name="org.rubypeople.*/feature.xml"/> ! <replacefilter token="${baseFeatureVersion}" value="${featureVersion}" /> ! </replace> ! <replace dir="${buildDirectory}/plugins"> ! <include name="org.rubypeople.*/plugin.xml"/> ! <replacefilter token="${baseFeatureVersion}" value="${featureVersion}" /> ! </replace> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do before generating the build scripts. --> ! <!-- ===================================================================== --> ! <target name="preGenerate"> ! <fail unless="featureVersion" message="Property featureVersion must be set. Either directly or in case of a nightly build with nightlyBuildFeatureVersionPrefix."/> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do after generating the build scripts. --> ! <!-- ===================================================================== --> ! <target name="postGenerate"> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do before running the build.xmls for the elements being built. --> ! <!-- ===================================================================== --> ! <target name="preProcess"> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do after running the build.xmls for the elements being built. --> ! <!-- ===================================================================== --> ! <target name="postProcess"> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do before running assemble. --> ! <!-- ===================================================================== --> ! <target name="preAssemble"> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do after running assemble. --> ! <!-- ===================================================================== --> ! <target name="postAssemble"> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do after the build is done. --> ! <!-- ===================================================================== --> ! <target name="postBuild"> ! <antcall target="test"/> ! <property name="UpdateSiteStagingLocation" value="${buildDirectory}/updateSite"/> ! <property name="sitePackagePrefix" value="org.rubypeople.updatesite"/> ! <antcall target="generateUpdateSite"/> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to test the build results --> ! <!-- ===================================================================== --> ! <target name="test" unless="dontRunTests"> ! <echo message="Setting up tests in ${eclipseAutomatedTestHome}"/> ! <copy file="${buildDirectory}/${buildLabel}/org.rubypeople.rdt-${buildId}.zip" tofile="${eclipseAutomatedTestHome}/eclipse-SDK-RDT-${buildId}.zip" /> ! <copy file="${buildDirectory}/${buildLabel}/org.rubypeople.rdt-tests-${buildId}.zip" tofile="${eclipseAutomatedTestHome}/eclipse-junit-tests-rdt-${buildId}.zip" /> ! <ant antfile="${eclipseAutomatedTestHome}/test.xml" target="runtests" dir="${eclipseAutomatedTestHome}"> ! <property name="os" value="${baseos}" /> ! <property name="ws" value="${basews}" /> ! <property name="arch" value="${basearch}" /> ! <property name="testPlugin" value="org.rubypeople.rdt.tests.all_${featureVersion}" /> ! <property name="report" value="org.rubypeople.rdt.tests.all" /> ! </ant> ! </target> ! <!--======================================================--> ! <!-- UpdateSite Export target --> ! <!-- ==================================================== --> ! <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 --> ! <antcall target="allElements"> ! <param name="genericTargets" value="${builder}/customTargets.xml"/> ! <param name="target" value="updateSiteExport"/> ! </antcall> ! <antcall target="copySiteXmlFromCvs"/> ! <antcall target="createNightlyBuildSiteXml"/> ! <delete dir="${buildDirectory}/temp.updatesite"/> ! </target> ! <target name="copySiteXmlFromCvs" unless="isNightlyBuild"> ! <!-- Grab the rest of the site out of CVS --> ! <mkdir dir="${buildDirectory}/temp.updatesite"/> ! <property name="cvsRoot" value=":ext:cvs.sf.net:/cvsroot/rubyeclipse" /> ! <cvs cvsRoot="${cvsRoot}" package="${sitePackagePrefix}" dest="${buildDirectory}/temp.updatesite" tag="HEAD"/> ! <!-- Copy to staging area --> ! <copy todir="${UpdateSiteStagingLocation}"> ! <fileset file="${buildDirectory}/temp.updatesite/${sitePackagePrefix}/site.xml"/> ! </copy> ! </target> ! <target name="createNightlyBuildSiteXml" if="isNightlyBuild"> ! <echo file="${UpdateSiteStagingLocation}/site.xml"><?xml version="1.0" encoding="UTF-8"?> ! <site> ! <description url="http://rubyeclipse.sourceforge.net/updatesite/nightly/"> The Ruby Development ! Tools update site. </description> ! <feature url="features/org.rubypeople.rdt_${featureVersion}.jar" id="org.rubypeople.rdt" version="${featureVersion}"> <category ! name="RubyEclipseNightlyBuild"/> </feature> ! <category-def name="RubyEclipseNightlyBuild" label="RDT Nigthly Build"> </category-def> </site> ! </echo> ! </target> ! <!-- ===================================================================== --> ! <!-- Steps to do to publish the build results --> ! <!-- ===================================================================== --> ! <target name="publish"> ! </target> ! <!-- ===================================================================== --> ! <!-- Default target --> ! <!-- ===================================================================== --> ! <target name="noDefault"> ! <echo message="You must specify a target when invoking this file" /> ! </target> ! </project> \ No newline at end of file |