How to fail a Maven build on a missing parameter?

build, environment-variables, java, maven-2, parameters

Solution

Yes, use the requireProperty goal of the maven-enforcer-plugin.

Problem

I have a environment variable or jvm parameter which must be present. How do I get Maven to fail if this parameter does not exist?

Original source

Related problems