v-m-p will never go looking for updates to plugins that are not referenced in your pom... but why would you be against adding a ref to the plugin in your pom.... unless the group id of the plugin is org.apache.maven.plugins or org.codehaus.mojo you will need to ref the plugin in your pom to use it (or ref it in your patent pom... in which case invoke v-m-p on the parent)... so if you want to use a plugin, you need to ref it in your pom (or parent) anyway.
the other thing is who says you have to check into scm the pom with the plugin added? so what is the cost of adding the plugin you want to check to your pom? worst case... cp pom.xml tmp-pom.xml vi tmp-pom.xml mvn versions:display-plugin-updates -f tmp-pom.xml rm tmp-pom.xml if your issue is finding out about new plugins that you have never heard of, Google and mailing lists, or searching central for artifacts with packaging of maven-plugin are the only ways - Stephen --- Sent from my Android phone, so random spelling mistakes, random nonsense words and other nonsense are a direct result of using swype to type on the screen On 26 Nov 2011 00:42, "Gabriel Belingueres" <[email protected]> wrote: > Hi all! Thanks for your answers. > > However, I have a doubt: Which would be the standard or most > productive method by which a maven user may know that a new plugin > version is available? > > Right now I know in 3 ways to find out of a new version: > > 1) Subscribe to the maven user mailing list and mark the [ANNOUNCE] > subjects. (somewhat productive). > 2) Check the maven/codehaus web sites in each plugin, follow a link of > a plugin goal, where in the full name appears the version number > (Example http://maven.apache.org/plugins/maven-jar-plugin/jar-mojo.html). > (very unproductive.) > 3) run a 'mvn versions:display-plugin-updates' (but only works for > explicit plugins declared in the pom). > > Wouldn't it be very productive if I could run a single maven plugin > goal that shows me of any new versions, regarding if "I'm not > interested in it since I'm not willing to declare it in my pom")? > I'm not saying that if a new plugin version is discovered, then > blindly replace the ones in the super pom (which would be very > dangerous of course). I just want to know they exists. > > Now...do the versions plugin have already the needed machinery to > provide a functionality like this? > > 2011/11/25 Stephen Connolly <[email protected]>: > > 2011/11/25 Gabriel Belingueres <[email protected]>: > >> Hi! > >> > >> I've runned with -U as you said, and even deleted the jar-plugin and > >> versions-plugin from my local repo and the same result: No mention of > >> jar plugin version 2.3.2. > >> > >> However, if I declare it in the pluginManagement tag: > >> > >> <pluginManagement> > >> <plugins> > >> <plugin> > >> <groupId>org.apache.maven.plugins</groupId> > >> <artifactId>maven-jar-plugin</artifactId> > >> <version>2.3.1</version> > >> </plugin> > >> </plugins> > >> </pluginManagement> > >> > >> then the versions plugin does says that there is a new 2.3.2 version. > >> > >> So my guess is that the versions plugin doesn't (or cannot?) check for > >> plugin versions defined in the super pom. > >> > > > > This is specifically by design. > > > > the versions plugin only works on the pom, not what is outside of the > > pom... thus if you run in a multi-module build and lock everything > > down in the root parent, the root parent will tell you of all the > > plugins that need to be upgraded and all the child plugins will say > > "all is fine"... except for that one errant child that specified a > > different plugin version ;-) > > > > Note that in the next release display-plugin-updates will only tell > > you when there are newer versions that work with the > > /project/prerequisites/maven version that you specify... but in those > > cases it will also tell you what version you can go to if you up the > > minimum required maven version... and the last thing I need to add > > (after i fix some bugs) is that it will warn if you are using plugins > > that require a newer version of maven than has been specified in > > /project/prerequisites/maven > > > > -Stephen > > > >> > >> 2011/11/25 Oleg Estekhin <[email protected]>: > >>> Hi > >>> > >>> Under some circumstances the maven checks for new versions in the local > >>> repository only. Force it to check the central explicitly with > >>> mvn -U versions:display-plugin-updates > >>> > >>> -----Исходное сообщение----- From: Gabriel Belingueres > >>> Sent: Monday, November 21, 2011 6:28 PM > >>> To: Maven Users List > >>> Subject: versions plugin does not show the maven-jar-plugin 2.3.2 as a > new > >>> version > >>> > >>> Hi! > >>> > >>> I'm using maven 3.0.3, which uses the maven-jar-plugin 2.3.1 as > >>> default (predefined in the super pom I think). > >>> > >>> If I run a mvn versions:display-plugin-updates then the > >>> maven-jar-plugin 2.3.2 does not shows in the list. > >>> > >>> Is it because I'm not explicitly declaring the use of the jar plugin > >>> in my pom.xml? That is, the versions plugin only works for the plugins > >>> I explicitly declare but not the ones in the super pom? > >>> > >>> Regards, > >>> Gabriel > >>> > >>> --------------------------------------------------------------------- > >>> To unsubscribe, e-mail: [email protected] > >>> For additional commands, e-mail: [email protected] > >>> > >>> > >>> --------------------------------------------------------------------- > >>> To unsubscribe, e-mail: [email protected] > >>> For additional commands, e-mail: [email protected] > >>> > >>> > >> > >> --------------------------------------------------------------------- > >> To unsubscribe, e-mail: [email protected] > >> For additional commands, e-mail: [email protected] > >> > >> > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [email protected] > > For additional commands, e-mail: [email protected] > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > >
