Enforce a minimum version of Maven
You can use the maven-enforcer-plugin
and its enforce
goal to specify a minimum required Maven version:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>1.4.1</version>
<executions>
<execution>
<id>enforce-maven</id>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<requireMavenVersion>
<version>3.2.5</version>
</requireMavenVersion>
</rules>
</configuration>
</execution>
</executions>
</plugin>
If someone tries to build the project with a Maven version less than 3.2.5, the build will fail.
You can enforce a lot of different rules with this plugin (Java version, OS...); see the complete list on the plugin documentation.