While the most popular way to run Maven is to specify goals, Maven provides a number of command-line options to customize its behavior. They range from specifying values for properties, to varying the verbosity of the Maven output. It is useful to know some of the arguments, as they will often help with troubleshooting issues with Maven.
To understand command-line options in Maven, perform the following steps:
Open the command prompt.
Run the following command:
mvn –h
You will see an output such as the following screenshot:
A number of options that Maven supports are displayed in the preceding screenshot.