Author: carlos
Date: Wed Jan 11 07:33:57 2006
New Revision: 368042

URL: http://svn.apache.org/viewcvs?rev=368042&view=rev
Log:
Added classpath usage docs

Added:
    maven/plugins/trunk/maven-antrun-plugin/src/site/apt/classpaths.apt   (with 
props)
Modified:
    maven/plugins/trunk/maven-antrun-plugin/src/site/apt/usage.apt
    maven/plugins/trunk/maven-antrun-plugin/src/site/site.xml

Added: maven/plugins/trunk/maven-antrun-plugin/src/site/apt/classpaths.apt
URL: 
http://svn.apache.org/viewcvs/maven/plugins/trunk/maven-antrun-plugin/src/site/apt/classpaths.apt?rev=368042&view=auto
==============================================================================
--- maven/plugins/trunk/maven-antrun-plugin/src/site/apt/classpaths.apt (added)
+++ maven/plugins/trunk/maven-antrun-plugin/src/site/apt/classpaths.apt Wed Jan 
11 07:33:57 2006
@@ -0,0 +1,140 @@
+ ----
+Using the classpaths
+ ----
+Carlos Sanchez
+ ----
+11 January 2006
+ ----
+
+Referencing the maven classpaths
+
+ You can use these classpath references:
+  
+  * <<<maven.dependency.classpath>>>
+
+  * <<<maven.compile.classpath>>>
+
+  * <<<maven.runtime.classpath>>>
+
+  * <<<maven.test.classpath>>>
+
+  * <<<maven.plugin.classpath>>>
+  
+
+Using optional ant tasks
+
+------
+<project>
+  <modelVersion>4.0.0</modelVersion>
+  <artifactId>my-test-app</artifactId>
+  <groupId>my-test-group</groupId>
+  <version>1.0-SNAPSHOT</version>
+
+  <build>
+    <plugins>
+
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-antrun-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>compile</id>
+            <phase>compile</phase>
+            <configuration>
+              <tasks>
+                <antlr target="calc.g" outputdirectory="target">
+                  <classpath refid="maven.plugin.classpath"/>
+                </antlr>
+              </tasks>
+            </configuration>
+            <goals>
+              <goal>run</goal>
+            </goals>
+          </execution>
+        </executions>
+        <dependencies>
+          <dependency>
+            <groupId>ant</groupId>
+            <artifactId>ant-antlr</artifactId>
+            <version>1.6.5</version>
+          </dependency>
+          <dependency>
+            <groupId>antlr</groupId>
+            <artifactId>antlrall</artifactId>
+            <version>2.7.4</version>
+          </dependency>
+        </dependencies>
+      </plugin>
+
+    </plugins>
+  </build>
+</project>
+------
+
+ or alternatively, using an external build.xml
+ (note the <<<inheritRefs>>> property so the classpath references are passed 
to the build.xml)
+
+------
+<project>
+  <modelVersion>4.0.0</modelVersion>
+  <artifactId>my-test-app</artifactId>
+  <groupId>my-test-group</groupId>
+  <version>1.0-SNAPSHOT</version>
+
+  <build>
+    <plugins>
+
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-antrun-plugin</artifactId>
+        <executions>
+          <execution>
+            <id>compile</id>
+            <phase>compile</phase>
+            <configuration>
+              <tasks>
+                <ant antfile="${basedir}/build.xml" inheritRefs="true">
+                  <target name="test"/>
+                </ant>
+              </tasks>
+            </configuration>
+            <goals>
+              <goal>run</goal>
+            </goals>
+          </execution>
+        </executions>
+        <dependencies>
+          <dependency>
+            <groupId>ant</groupId>
+            <artifactId>ant-antlr</artifactId>
+            <version>1.6.5</version>
+          </dependency>
+          <dependency>
+            <groupId>antlr</groupId>
+            <artifactId>antlrall</artifactId>
+            <version>2.7.4</version>
+          </dependency>
+        </dependencies>
+      </plugin>
+
+    </plugins>
+  </build>
+</project>
+------
+
+ The build.xml:
+
+------
+<?xml version="1.0"?>
+<project name="test6">
+
+    <target name="test">
+
+        <antlr target="calc.g" outputdirectory="target">
+            <classpath refid="maven.plugin.classpath"/>
+        </antlr>
+
+    </target>
+
+</project>
+------

Propchange: maven/plugins/trunk/maven-antrun-plugin/src/site/apt/classpaths.apt
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: maven/plugins/trunk/maven-antrun-plugin/src/site/apt/classpaths.apt
------------------------------------------------------------------------------
    svn:keywords = "Author Date Id Revision"

Modified: maven/plugins/trunk/maven-antrun-plugin/src/site/apt/usage.apt
URL: 
http://svn.apache.org/viewcvs/maven/plugins/trunk/maven-antrun-plugin/src/site/apt/usage.apt?rev=368042&r1=368041&r2=368042&view=diff
==============================================================================
--- maven/plugins/trunk/maven-antrun-plugin/src/site/apt/usage.apt (original)
+++ maven/plugins/trunk/maven-antrun-plugin/src/site/apt/usage.apt Wed Jan 11 
07:33:57 2006
@@ -54,18 +54,6 @@
   a new phase.
 
   
-  You can use these classpath references:
-  
-  * <<<maven.dependency.classpath>>>
-
-  * <<<maven.compile.classpath>>>
-
-  * <<<maven.runtime.classpath>>>
-
-  * <<<maven.test.classpath>>>
-
-  * <<<maven.plugin.classpath>>>
-  
   Below you can see how to indicate that ant has generated some more java
   source that needs to be included in the compilation phase. Note that the
   compile phase follows the generate-sources phase in the lifecycle.

Modified: maven/plugins/trunk/maven-antrun-plugin/src/site/site.xml
URL: 
http://svn.apache.org/viewcvs/maven/plugins/trunk/maven-antrun-plugin/src/site/site.xml?rev=368042&r1=368041&r2=368042&view=diff
==============================================================================
--- maven/plugins/trunk/maven-antrun-plugin/src/site/site.xml (original)
+++ maven/plugins/trunk/maven-antrun-plugin/src/site/site.xml Wed Jan 11 
07:33:57 2006
@@ -35,6 +35,7 @@
     <menu name="Overview">
       <item name="Introduction" href="introduction.html"/>
       <item name="Usage" href="usage.html"/>
+      <item name="Using classpaths" href="classpaths.html"/>
     </menu>
 
     ${reports}


Reply via email to