Hi all,

I wanted to use the maven.plugin.classpath (see [1]), but it seems that
this variable does not exist any more
  > Embedded error: Reference maven.plugin.classpath not found.
It is normal ?

My context :
------------------
I want to use the antrun plugin like this

<plugin>
   <artifactId>maven-antrun-plugin</artifactId>
   <version>1.0</version>

    <dependencies>
       <dependency>
           <artifactId>xdoclet-apache-module</artifactId>
           <groupId>xdoclet</groupId>
           <version>1.2.3</version>
           <type>jar</type>
       </dependency>
       [...]
    </dependencies>

   <executions>
       <execution>
           <phase>generate-sources</phase>
           <goals>
               <goal>run</goal>
           </goals>
           <configuration>
               <tasks>

                   <taskdef
                       name        = "webdoclet"
                       classname    = "xdoclet.modules.web.WebDocletTask"
                       classpathref= "maven.plugin.classpath"
                   />

but it's not working : > Embedded error: Reference
maven.plugin.classpathnot found.

So I need to do like this :

   <dependencies>
       <dependency>
           <artifactId>xdoclet-apache-module</artifactId>
           <groupId>xdoclet</groupId>
           <version>1.2.3</version>
           <type>jar</type>
       </dependency>
       [...]
    </dependencies>

   <build>
     <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
        <version>1.0</version>

       <executions>
           <execution>
               <phase>generate-sources</phase>
               <goals>
                   <goal>run</goal>
               </goals>
               <configuration>
                   <tasks>

                       <taskdef
                           name        = "webdoclet"
                           classname    = "
xdoclet.modules.web.WebDocletTask"
                           classpathref= "maven.dependency.classpath"
                       />


But it's not very nice because maven put all the xdoclet dependencies in the
WEB-INF/lib.

It is not possible also to use the scope provided because the
maven.dependency.classpath
don't take into account this scope.

What can I do ?
Thanks,

Rémy


[1] http://maven.apache.org/plugins/maven-antrun-plugin/classpaths.html

Reply via email to