此规则检查构建期间使用的插件集,并强制不使用特定的排除插件。
此规则支持以下参数:
示例插件配置:
<project>
[...]
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.0.0</version>
<executions>
<execution>
<id>enforce-banned-dependencies</id>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<bannedPlugins>
<excludes>
<exclude>org.codehaus.mojo:build-helper-maven-plugin</exclude>
</excludes>
</bannedPlugins>
</rules>
<fail>true</fail>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
[...]
</project>