maven新建项目时报错

时间:2021-06-17 15:55:38
Could not calculate build plan: Plugin org.apache.maven.plugins:maven-resources-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-resources-plugin:jar:2.5 

Plugin org.apache.maven.plugins:maven-resources-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-resources-plugin:jar:2.5


解决方法:

1、查看windows -> Preferences -> maven 的settings.xml文件中.m2的位置

2、然后将.m2/repository/org/apache/maven/plugins目录下的文件夹全部删除

3、选中maven项目,右键--》maven--》update让maven重新下载依赖包

问题解决

【注】此IDE自带maven插件,不需要再自己下载安装maven插件