-
Notifications
You must be signed in to change notification settings - Fork 116
Maven wrapper
With version 4.2.0, the maven wrapper was introduced.
The Maven Wrapper is an easy way to ensure a user of your Maven build has everything necessary to run your Maven build.
The official documentation is here.
Normally you instruct users to install a specific version of Apache Maven, put
it on the PATH and then run the mvn
command like the following:
mvn clean install
But now, with a Maven Wrapper setup, you can instruct users to run wrapper scripts:
./mvnw clean install
or on Windows
mvnw.cmd clean install
A normal Maven build will be executed with the one important change that if the
user doesn't have the necessary version of Maven specified in
.mvn/wrapper/maven-wrapper.properties
it will be downloaded for the user
first, installed and then used.
Subsequent uses of mvn
/mvnw.cmd
use the previously downloaded, specific
version as needed.