maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Karl Heinz Marbaise <khmarba...@gmx.de>
Subject Re: How does maven choose which plugin version to use?
Date Mon, 04 Jul 2016 05:12:14 GMT
Hi,

yes in general your assumptions are right but you should always
define the plugin versions yourself which means to define them
via pluingManagement.

<build>
     ...
     <pluginManagement>
       <plugins>
         <plugin>
           <groupId>org.apache.maven.plugins</groupId>
           <artifactId>maven-war-plugin</artifactId>
           <version>2.6</version>
         </plugin>
          ...
       </plugins>
     </pluginManagement>
     ...
   </build>
</project>

and best practice is to define all plugins here.

Usually you should create a corporate pom which you can inherit from in 
every project something like this:

https://github.com/khmarbaise/smpp

Kind regards
Karl Heinz Marbaise

On 7/3/16 11:45 PM, Alex Ditu wrote:
> Hello,
>
> Can anyone provide some help regarding plugin versions? I want to use
> the latest version of maven-war-plugin (or at least one greater than
> 2.3); so i decided to install the latest version of maven, 3.3.9.
> But when I execute "mvn help:effective-pom" I see it still uses 2.3
> version of maven-war-plugin.
> My first question is: where does maven read wich plugin version to
> use, if I don't specify one?
> I tought it was in the super-pom, but I didn't find anything
> there...Can anyone help me understand what is happening?
>
> Alex
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>


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


Mime
View raw message