How can I enforce that my custom Maven Plugin (or only a certain Mojo within) is only executed with at least a certain Java version (i.e. Java8 due to the use of class files being only compatible with Java8+). The prerequisites section which seems like the natural way to define that only allows me to require a minimum Maven version (http://maven.apache.org/ref/3.5.0/maven-model/maven.html#class_prerequisites). which is not what I want here.
The failure message is rather unintuitive whenever my Maven Mojo is used in a project with an incompatible Java version (which cannot read my Mojos class files). I know that in all Projects using the Maven Plugin the maven-enforcer-plugin could theoretically be used, but then each consuming projects needs to manually figure out the minimum java version based on the documentation of all Maven Plugins. Isn't there a better/more automated way, which let's Maven check this requirement prior to executing any Mojos from a plugin? Thanks, Konrad --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org