Create maven project and ideamaven project with IDEA for the first time
First use IDEA, create a maven project, first download maven, official address: http://maven.apache.org/download.cgi
Decompress, configure D: \ maven \ apache-maven-3.5.2 \ bin in the path in the environment variable, open cmd, enter mvn-version to check whether the configuration is successful
Open IDEA, new project, select maven Project, and select your jdk as the project SDK,
Select a webapp project and click next. The GroupId is the group name (generally the domain name + company name or name), the ArtifactId is the module name (that is, the project name), and the next, enter the locally decompressed maven path in the maven path and change setting. xml Path. Create a mavenrepository file under maven as a maven repository and open setting. xml, add a <localRepository> (repository address) </localRepository>, IDEA automatically identifies the repository address, click the plus sign under Propertities, Name: archetypeCatalog, Value: internal, click next, enter the project name and work interval, and click finish. Wait for maven to load the jar package. The prompt "maven project need to be imported" appears in the lower right corner. Select enable auto-imported and the jar will be automatically downloaded to the local repository in pom. configure xml, Baidu maven repository, search for maven compiler plugin, select the latest version, and click <plugins> <plugin> </plugins>.
<Configuration> <source/> <target/> <encoding/> (JDK version) </configuration>. The configuration of pom. xml is complete.
Right-click the project and open module setting to create the project directory.
The project is complete.
In tomcat Configuration, click Edit deployments, click +, and select Tomcat. If Local Tomcat is used, select Configuration of Application Server in server, find the Local Tomcat Server, and click + in Deployment, select the project to be deployed and select the access path in Application context to run tomcat.