Brief Introduction
One of the MAVEN uses is to build, a very powerful build tool that automates builds, from cleaning, compiling, testing to generating reports, and then packaging and deploying.
Install maven
Connection: http://blog.csdn.net/weisheixiaoxin/article/details/75078748 Eclipse Create project install maven
Open Eclipse->window->preferences->maven
Referencing the MAVEN plug-in
Configuring settings files and local warehouses
The default path is: ${user.home}/.m2/repository
Custom Warehouse Address: Open settings.xml file
Create maven Project
Open File->new->maven Project
MAVEN defines the basic coordinates of the project using the group Id,artifact Id,version ternary, and the Jar,pom,war in packaging is differentiated by these basic coordinates, and the execution of the packaging command is either a jar package or a war package.
Where the group ID of multiple items can be consistent but the artifact ID must be unique for the same group, version specifies the current project, and snapshot means the snapshot indicates that the project is in an unstable version of development.
Modify Project
Modify file characters to UTF-8
Modifying a compiled version
Cancel Dynamic Web Module (click Apply to save)
The WebContent folder is generated after checking the dynamic Web Module (click Apply Save).
Move the Web-inf and Meta-inf as WebApp and remove the build path.
Publish to the root directory when the WebApp directory is built
Maven Project created successfully ... IntelliJ Idea Create a project Install maven
Create maven Project
Select JDK Select a Web model next
To create a project Hello2, there is a problem with the same group only if it is not unique to install to the local warehouse, the next step.
Project Development Address
Waiting to wait ... IntelliJ can create a project according to the web model you just selected, (Eclipse can also create the first map of the MAVEN project, remove the Create a simple project, and the next step is to select the Web model), of course IntelliJ You can also create a blank Maven project.
Modify Project
Create Java directory, mark as resource file
Modify post-compile address
Add a resource path
Deployment path
New publishing information for the description file
Save
deploying to a Tomcat server
running the server
Success...