It will create the collection of war plugins and package all to the classes, artifacts, dependencies and resources of the web application.
Let us try creating war file using maven, using our traditional approach,
First create templates like we created for jar file.Type mvn archetype:generate
Choose a number or apply filter (format: [groupID:}artifactId, case sensitive contains):choose the type of war, here we are choosing. maven-archetype-quickstart
Choose a number or apply filter (format: [groupId:]artifactId, case sensitive contains): choose the archetype. org.apache.maven.archetypes:maven-archetype-quickstart version.
Choose org.apache.maven.archetypes:maven-archetype-quickstart version: choose the latest version, 9.
Define value for property 'groupId': give a unique group id, say, com.fresco.play
Define value for property 'artifactId': give first-war-project
Define value for property 'version' 1.0-SNAPSHOT: give 1.0-SNAPSHOT
Define value for property 'package' com.madanswer provide the suggested name i.e., com.madanswer
Confirm by selection Y: Y
- The build is successful with BUILD SUCCESS message. It is time to create your own first maven project.