1. Create a new MAVEN project and right-click on the project selection-->properties--> Select Javabuildpath-->source-->addfolder, add src/main/resources and src/ Test/resources
2. Double-click the output folder under Src/test/java and Src/test/resources, and set the class publishing directory for the test code compilation to Target/test-classes. In order to not be mixed with the official code compiled files, the official code publishing directory using the default target/classes.
3. Adjust the display order of the folder in order and export
4. Double-click in libraries to replace the default JRE with your own JRE
5. Convert to a Dynamic Web project so that Tomcat recognizes
Click on the left side of Project Facets, on the right, select dynamic Web Module-----set version to 2.5 (default 3.0 for Java7), and temporarily do not click OK
6. Click on the further configuration available ..... set Web. XML in the directory of Src/main/webapp, Apply
7. Click Deployment Assembly on the left to delete the two test folder that you do not need to deploy
8. Set up a package that releases Maven dependencies at the same time
Click Add, double-click Java Build Path Entries, double-click Maven Dependencies-OK
9. Project
10. Configure Maven auto-download jar
1. Specify the URL of the download jar in the C:\User\ user name \.m2\settings.xml file
2. Specify the coordinates of the jar in the Pom.xml file in the project
At this point, a completed MAVEN project is completed.
Eclipse creates a Maven project