Creating project in Maven

Just fire up command prompt, create new directory and execute below command from that directory.
 
mvn archetype:generate -DgroupId=”org.softpost” -DartifactId=maventut 
-DarchetypeArtifactId=maven-archetype-quickstart  -DinteractiveMode=false

If everything goes fine, maven will download required resources and finally create the sample maven project in the given directory. It creates project directories as per the maven standard directory layout. Here is the sample output of above command in windows power shell. To compile the project, we can execute below command.
 
mvn compile

To execute tests from the project, we can execute below command.
 
mvn test

Complex problems, Simple Solutions