Hi Karl Heinz,
For Maven2 all arguments are immediately processed, you can't trace back
the values of -pl or -amd.
I think you should go for the easy and solid solution by requiring
specific Maven versions.
For instance: In the rule, read the version value of
/META-INF/maven/org.apache.maven/maven-core/pom.properties
Robert
Op Wed, 26 Mar 2014 21:25:25 +0100 schreef Karl Heinz Marbaise
<[email protected]>:
Hi to all devs...
currently I'm struggling with the above implementation. The current
implementation works fine with all tests etc. But based on the above
issue (of course needed)....
So if i like to check the Maven -pl Options ..
Robert Scholte already gave me some hints to use things like this
(Thanks for that):
mavenSession.getRequest().getSelectedProjects();
unfortunately the getRequest() method is first available with release
3.X of Maven core which is currently not used in Maven Enforcer plugin
(currently using Maven 2.0.6)..
The current implementation is going via:
session = (MavenSession) helper.evaluate( "${session}" );
..
List<MavenProject> sortedProjects = session.getSortedProjects();
which works for Maven 2.0.X, 2.2.1, Maven 3.1.X and Maven 3.2.X...
Can someone give me hint if it's possible to hold compatibility with the
above and find out "-pl -amd" things ?
Maven 2.2.1 know the options "-pl, -amd" so this might be the first
version with which it could work ....
Thanks in advance....
Kind regards
Karl-Heinz Marbaise
---------------------------------------------------------------------
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]