maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrachan <>
Subject Activate a profile based on Maven version?
Date Thu, 04 Nov 2010 09:18:35 GMT

Is there a way to activate or de-activate a profile based on the maven

As background, I'd like builds to be based on Maven 3.0; but various plugin
versions (e.g. site 3.0.x) don't work on older Maven 2.x versions. However
to work nicely in Hudson its handy to keep the build working on 2.x as well.

So I use an 'm2' profile to override the various 3.x specific maven plugins
with the older 2.x compatible versions. Lovely!

However what I'd really like is for the m2 profile to automatically activate
if the user running the build has an older Maven version. Sure its a nice to
have, I just think until everyone's tool chains move off of 2.x of Maven
it'd be nice for builds to work on 2.x and 3.x without folks having to
remember to activate/deactivate a profile.  Is there a way of doing this
using the property stuff maybe?
View this message in context:
Sent from the Maven - Users mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message