在IDEA里新建maven时出现报错,报错如下:
Project:
****:1.0-SNAPSHOT
Location:
****/pom.xml
Problems:
Unresolved plugin: 'org.apache.maven.plugins:maven-compiler-plugin:3.1'
Unresolved plugin: 'org.apache.maven.plugins:maven-surefire-plugin:2.12.4'
Unresolved plugin: 'org.apache.maven.plugins:maven-install-plugin:2.4'
Unresolved plugin: 'org.apache.maven.plugins:maven-deploy-plugin:2.7'
Unresolved plugin: 'org.apache.maven.plugins:maven-site-plugin:3.3'
学习了这篇笔记后成功解决该问题,笔记链接如下:
https://blog.csdn.net/biaoguaqie7838/article/details/106179663spm=1001.2014.3001.5501
步骤一:在pom.xml里键入dependencies里的代码(代码已附在后面)
步骤二:等待包的下载
步骤三:点击下图中的Reload Project
步骤四:等待下载完成,报错解除
补充:
在dependency中重新定义:
org.apache.maven.plugins
maven-compiler-plugin
3.2
maven-plugin