Generic Plugin configuration information

The enforcer:enforce and enforcer:enforce-once mojos

These goals are meant to be bound to a lifecycle phase and configured in your pom.xml. The enforcers execute the configured rules to check for certain constraints. The available standard rules are described here. Besides the rules to execute, these goals support three options:

skip - a quick way to skip checks via a profile or using -Denforcer.skip=true from the command line.

fail - if the goal should fail the build when a rule fails. The default is true. If false, the errors will be logged as warnings.

failFast - if the goal should stop checking after the first failure. The default is false.

Each rule to be executed should be added to the rules element along with the specific configuration for that rule.

As of version 2.0 you may add a level element to the standard rules. Valid values are WARN and ERROR. When levelWARN is specified, the rule will only spit out a warning but will not fail the build.

The enforce goal executes against each project in a multi-project build. The enforce-once goal executes just once per build. This is most effective for the standard rules because the Maven, Java and OS versions will not change between projects in the same build.