kaz 02/05/14 14:51:41
Modified: . build-bootstrap.xml
src/templates/build Control.vm build.xml
Log:
- The sample build file in src/templates/build was being manually edited
when new delegators were being added. The delegates in this file
should be autogenerated and the delegations should be placed in the
Control.vm file instead. The autogeneration of delegates also picks
up delegations that have been added by the plugins' Control.vm files.
- Updated several missing delegates in the Control.vm file.
- build-bootstrap no longer blindly copies src/templates/build/build.xml.
Instead, the build.xml file is generated into the temporary build
directory in an examples directory. (The bootstrap copies the entire
build directory into the maven installation directory so the
example build.xml file ends up in the right place)
Revision Changes Path
1.82 +0 -5 jakarta-turbine-maven/build-bootstrap.xml
Index: build-bootstrap.xml
===================================================================
RCS file: /home/cvs/jakarta-turbine-maven/build-bootstrap.xml,v
retrieving revision 1.81
retrieving revision 1.82
diff -u -r1.81 -r1.82
--- build-bootstrap.xml 14 May 2002 00:07:59 -0000 1.81
+++ build-bootstrap.xml 14 May 2002 21:51:41 -0000 1.82
@@ -329,11 +329,6 @@
file="project.properties"
/>
- <copy
- toDir="${maven.home}/examples"
- file="src/templates/build/build.xml"
- />
-
</target>
<!-- ================================================================== -->
1.20 +44 -18 jakarta-turbine-maven/src/templates/build/Control.vm
Index: Control.vm
===================================================================
RCS file: /home/cvs/jakarta-turbine-maven/src/templates/build/Control.vm,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- Control.vm 14 May 2002 17:59:42 -0000 1.19
+++ Control.vm 14 May 2002 21:51:41 -0000 1.20
@@ -40,48 +40,64 @@
## Make our list of build.xml delegators
## -------------------------------------------------------
-$delegators.put("env","build-maven.xml")
-$delegators.put("update-jars","build-maven.xml")
-$delegators.put("compile","build-maven.xml")
-$delegators.put("jar","build-maven.xml")
-$delegators.put("dist","build-maven.xml")
-$delegators.put("install-jar","build-maven.xml")
-$delegators.put("gump-descriptor","build-maven.xml")
-$delegators.put("clean","build-maven.xml")
+$delegators.put("jar", "build-maven.xml")
+$delegators.put("install-jar", "build-maven.xml")
+$delegators.put("env", "build-maven.xml")
+$delegators.put("clean", "build-maven.xml")
+$delegators.put("dist", "build-maven.xml")
+$delegators.put("dist-build", "build-maven.xml")
+$delegators.put("deploy-dist", "build-maven.xml")
+$delegators.put("gump-descriptor", "build-maven.xml")
+$delegators.put("compile", "build-maven.xml")
+$delegators.put("check-source", "build-maven.xml")
+$delegators.put("update-jars", "build-maven.xml")
+$delegators.put("announce", "build-maven.xml")
+$delegators.put("maven-update", "build-maven.xml")
+$delegators.put("validate-pom", "build-maven.xml")
+$delegators.put("verify-project", "build-maven.xml")
## -------------------------------------------------------
## Make our list of build-test.xml delegators
## -------------------------------------------------------
-$delegators.put("test","build-test.xml")
+$delegators.put("test", "build-test.xml")
+$delegators.put("run-singletest", "build-test.xml")
## -------------------------------------------------------
## Make our list of build-iutest.xml delegators
## -------------------------------------------------------
-$delegators.put("iutest","build-iutest.xml")
+$delegators.put("iutest", "build-iutest.xml")
## -------------------------------------------------------
## Make our list of build-metrics.xml delegators
## -------------------------------------------------------
-$delegators.put("metrics","build-metrics.xml")
+$delegators.put("metrics", "build-metrics.xml")
## -------------------------------------------------------
## Make our list of build-docs.xml delegators
## -------------------------------------------------------
-$delegators.put("docs","build-docs.xml")
-$delegators.put("javadocs","build-docs.xml")
-$delegators.put("site","build-docs.xml")
-$delegators.put("deploy-site","build-docs.xml")
-
-$delegators.get("deploy-site")
+$delegators.put("site", "build-docs.xml")
+$delegators.put("fo", "build-docs.xml")
+$delegators.put("pdf", "build-docs.xml")
+$delegators.put("docs", "build-docs.xml")
+$delegators.put("docs-quick", "build-docs.xml")
+$delegators.put("deploy-site", "build-docs.xml")
+$delegators.put("cross-ref", "build-docs.xml")
+$delegators.put("cvs-change-log", "build-docs.xml")
+$delegators.put("activity-log", "build-docs.xml")
+$delegators.put("task-list", "build-docs.xml")
+$delegators.put("javadocs", "build-docs.xml")
## -------------------------------------------------------
-## Make our list of build-docs.xml delegators
+## Make our list of build-reactor.xml delegators
## -------------------------------------------------------
+$delegators.put("generate-reactor","build-reactor.xml")
+
+
#set ($outputDir = "maven")
#set ($mavenDirectory = "${maven.home}")
$files.mkdir($outputDir)
@@ -115,8 +131,18 @@
#end
#end
+## -------------------------------------------------------
+## Generate an example build file that contains all of the
+## delegators so users can use this as a starting point.
+## -------------------------------------------------------
+
+$files.mkdir("$outputDir/examples")
+$generator.parse("build.xml","$outputDir/examples/build.xml")
+
+## -------------------------------------------------------
## We don't want to overwrite an existing build.xml file
## or project.properties if they exist.
+## -------------------------------------------------------
#if (!$files.file("build.xml").exists())
$generator.parse("build.xml","build.xml")
1.39 +4 -141 jakarta-turbine-maven/src/templates/build/build.xml
Index: build.xml
===================================================================
RCS file: /home/cvs/jakarta-turbine-maven/src/templates/build/build.xml,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -r1.38 -r1.39
--- build.xml 12 May 2002 13:41:07 -0000 1.38
+++ build.xml 14 May 2002 21:51:41 -0000 1.39
@@ -18,150 +18,13 @@
<!-- D E L E G A T O R S -->
<!-- ================================================================== -->
- <target name="maven:site">
- <ant antfile="$mavenDirectory/build-docs.xml" target="site"/>
- </target>
-
- <target name="maven:fo">
- <ant antfile="$mavenDirectory/build-docs.xml" target="docs:fo"/>
- </target>
-
- <target name="maven:pdf">
- <ant antfile="$mavenDirectory/build-docs.xml" target="docs:pdf"/>
- </target>
-
- <target name="maven:jar">
- <ant antfile="$mavenDirectory/build-maven.xml" target="jar"/>
- </target>
-
- <target name="maven:install-jar">
- <ant antfile="$mavenDirectory/build-maven.xml" target="install-jar"/>
- </target>
-
- <target name="maven:env">
- <ant antfile="$mavenDirectory/build-maven.xml" target="env"/>
- </target>
-
- <target name="maven:docs">
- <ant antfile="$mavenDirectory/build-docs.xml" target="docs"/>
- </target>
-
- <target name="maven:docs-quick">
- <ant antfile="$mavenDirectory/build-docs.xml" target="docs-quick"/>
- </target>
-
- <target name="maven:test">
- <ant antfile="$mavenDirectory/build-test.xml" target="test"/>
- </target>
-
- <target name="maven:iutest">
- <ant antfile="$mavenDirectory/build-iutest.xml" target="test"/>
- </target>
-
- <target name="maven:singletest">
- <ant antfile="$mavenDirectory/build-test.xml" target="run-singletest"/>
- </target>
+#foreach ($delegator in $delegators.keySet())
- <target name="maven:clean">
- <ant antfile="$mavenDirectory/build-maven.xml" target="clean"/>
- </target>
-
- <target name="maven:metrics">
- <ant antfile="$mavenDirectory/build-metrics.xml" target="metrics"/>
- </target>
-
- <target name="maven:dist">
- <ant antfile="$mavenDirectory/build-maven.xml" target="dist"/>
- </target>
-
- <target name="maven:dist-build">
- <ant antfile="$mavenDirectory/build-maven.xml" target="dist-build"/>
- </target>
-
- <target name="maven:deploy-site">
- <ant antfile="$mavenDirectory/build-docs.xml" target="deploy-site"/>
- </target>
-
- <target name="maven:deploy-dist">
- <ant antfile="$mavenDirectory/build-maven.xml" target="deploy-dist"/>
- </target>
-
- <target name="maven:gump-descriptor">
- <ant antfile="$mavenDirectory/build-maven.xml" target="gump-descriptor"/>
- </target>
-
- <target name="maven:cross-ref">
- <ant antfile="$mavenDirectory/build-docs.xml" target="cross-ref"/>
- </target>
-
- <target name="maven:cvs-change-log">
- <ant antfile="$mavenDirectory/build-docs.xml" target="cvs-change-log"/>
+ <target name="maven:$delegator">
+ <ant antfile="$mavenDirectory/$delegators.get($delegator)"
target="$delegator"/>
</target>
- <target name="maven:activity-log">
- <ant antfile="$mavenDirectory/build-docs.xml" target="activity-log"/>
- </target>
-
- <target name="maven:task-list">
- <ant antfile="$mavenDirectory/build-docs.xml" target="task-list"/>
- </target>
-
- <target name="maven:javadocs">
- <ant antfile="$mavenDirectory/build-docs.xml" target="javadocs"/>
- </target>
-
- <target name="maven:compile">
- <ant antfile="$mavenDirectory/build-maven.xml" target="compile"/>
- </target>
-
- <target name="maven:check-source">
- <ant antfile="$mavenDirectory/build-maven.xml" target="check-source"/>
- </target>
-
- <target name="maven:update-jars">
- <ant antfile="$mavenDirectory/build-maven.xml" target="update-jars"/>
- </target>
-
- <target name="maven:announce">
- <ant antfile="$mavenDirectory/build-maven.xml" target="announce"/>
- </target>
-
- <target name="maven:maven-update">
- <ant antfile="$mavenDirectory/build-maven.xml" target="maven-update"/>
- </target>
-
- <target name="maven:validate-pom">
- <ant antfile="$mavenDirectory/build-maven.xml" target="validate-pom"/>
- </target>
-
- <target name="maven:xdocs">
- <ant antfile="$mavenDirectory/build-docs.xml" target="generate-xdocs"/>
- </target>
-
- <target
- name="maven:generate-reactor">
- <ant antfile="$mavenDirectory/build-reactor.xml" target="generate-reactor"/>
- </target>
-
- <target
- name="maven:verify-project">
- <ant antfile="$mavenDirectory/build-maven.xml" target="verify-project"/>
- </target>
-
- <target
- name="maven:war">
- <ant antfile="$mavenDirectory/build-j2ee.xml" target="war"/>
- </target>
-
- <target
- name="maven:validate-war">
- <ant antfile="$mavenDirectory/build-j2ee.xml" target="validate-war"/>
- </target>
-
- <target
- name="maven:ear">
- <ant antfile="$mavenDirectory/build-j2ee.xml" target="ear"/>
- </target>
+#end
<!-- maven:end -->
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>