maven-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brian E. Fox" <bri...@reply.infinity.nu>
Subject RE: Default plugin execution id
Date Fri, 07 Nov 2008 20:53:58 GMT
Yes, this is needed. I have a jira somewhere for it...
http://jira.codehaus.org/browse/MNG-3401


-----Original Message-----
From: Paul Gier [mailto:pgier@redhat.com] 
Sent: Friday, November 07, 2008 3:46 PM
To: Maven Developers List
Subject: Default plugin execution id

Hi everyone,

I'd like to be able to configure the default execution of a plugin
within an 
execution instead of doing it through the main plugin configuration.  So
the 
result would look something like this:

<plugin>
   <groupId>org.apache.maven.plugins</groupId>
   <artifactId>maven-jar-plugin</artifactId>
   <executions>
     <execution>
       <id>default</id>
       <configuration>
         <includes>
           <include>stuff/**</include>
         </includes>
       </configuration>
     </execution>
     <execution>
       <id>custom</id>
       <configuration>
         <includes>
           <include>other-stuff/**</include>
         </includes>
       </configuration>
     </execution>
   </executions>
</plugin>

Currently, it seems the only way to configure the default jar plugin
execution 
is to use the main plugin configuration section.  This doesn't work as
well 
because it ends up applying the config to all executions, which is not
always 
what is needed.

Benjamin pointed me to the MojoExceution constructor which sets the id
to null, 
and PluginExecution from the model which sets the id to "default".  This

difference seems to be why the default executions can't be overridden in
an 
execution config.

Any thoughts?  I'll create a jira issue with a patch for this, but I'll
wait for 
  feedback before changing anything.

Thanks!


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Mime
View raw message