I am wonder how maven know which archetype is used for specified pom.xml
I didn’t find any difference between pom.xml of maven-archetype-quickstart and that of maven-archetype-webapp.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
These are two different Questions:
The archetype plugin is usually used interactively. You just call
mvn archetype:create, and the wizard walks you through the different steps. There’s nothing you need to configure in a pom. In fact it would be silly to put archetype information in an existing project, as archetypes are for creating new projects.The main difference is that webapp contains a folder src/main/webapp which contains your static web resources and the WEB-INF folder. Also, the packaging is set to
war. Somaven-archetype-quickstartis the default for creating a simple jar project, whilemaven-archetype-webappis the default for creating a simple war project.