Details
-
Bug
-
Status: Closed
-
Blocker
-
Resolution: Cannot Reproduce
-
1.0-alpha-3, 1.0
-
None
-
None
Description
http://maven.apache.org/plugins/maven-enforcer-plugin/rules/requirePluginVersions.html describes how to configure the plugin.
But by default it won't work, because you have to specify the version of the enforcer plugin itself.
If you pick 1.0-alpha-3, you get
[INFO] Failed to configure plugin parameters for: org.apache.maven.plugins:maven-enforcer-plugin:1.0-alpha-3
Cause: Class 'org.apache.maven.shared.enforcer.rule.api.EnforcerRule' cannot be instantiated
If you pick 1.0-alpha-4-SNAPSHOT (which would fail the rule anyway, but...), you get
[ERROR] FATAL ERROR
[INFO] ------------------------------------------------------------------------
[INFO] org.apache.maven.plugins.enforcer.DefaultEnforcementRuleHelper.<init>(Lorg/apache/maven/execution/MavenSession;Lorg/codehaus/plexus/component/configurator/expression/ExpressionEvaluator;Lorg/apache/maven/plugin/logging/Log;)V
[INFO] ------------------------------------------------------------------------
[INFO] Trace
java.lang.NoSuchMethodError: org.apache.maven.plugins.enforcer.DefaultEnforcementRuleHelper.<init>(Lorg/apache/maven/execution/MavenSession;Lorg/codehaus/plexus/component/configurator/expression/ExpressionEvaluator;Lorg/apache/maven/plugin/logging/Log;)V