The pom.xml file cannot be recognized by idea

question

The pom.xml file cannot be recognized by idea

detailed question

Please add a picture description
The author imports a project that has been developed on another person's computer. After importing, the pom.xml file cannot be recognized by idea, and at the same time, other dependencies cannot be imported by refreshing maven.

solution

1 Right button pom.xml → \rightarrow clickAdd as Maven Project insert image description here
2 to update maven changes (or useCtrl + Shfit + O)
insert image description here

reason

The reason for this problem may be that the project developed on other people's computers is opened using eclipse, and imported from eclipse to idea, the pom.xml file cannot be directly recognized by maven. Right-click the pom.xml file and select "add as maven project", then the project can be set as a maven-based project, and the required dependencies can be obtained by updating the maven changes.

insert image description here

Guess you like

Origin blog.csdn.net/T_Y_F_/article/details/130071275