How to create a Maven Project - For Beginner

Create a Maven Project

Apache Maven Project

1 - Create a Dynamic Web Project :


Create new dynamic web project

2  -  Create the name of your project and click next


Project name dynamic web project

3 - remove the src folder

click add folder
add : src/main/java
         src/main/resources
         src/main/test
         src/main/webapp


Source Folder configuration dynamic web project

and click next


Source Folder configuration dynamic web project

change the Content directoryand check the Generate web.xml deployment descriptor


configure web module settings

 4 - change the Dynamic web Project  to Maven Project


convert dynamic web project to maven project

5 - Generate The Pom.xml

Specify the : GroupId & ArtifactId
Packaging :  war = a web project
                     jar = a jar project

Click finish


maven groupId and ArtifactId


final maven project


Comments