下载maven-resources-plugin-2.5.jar的网址不能访问。
添加镜像,
C:\Program Files\apache-maven-3.3.9\conf\settings.xml,有同学不知道settings.xml的位置,这里列一下。
=======================================settings.xml=================================================
<mirrors>
<!-- mirror
| Specifies a repository mirror site to use instead of a given repository. The repository that
| this mirror serves has an ID that matches the mirrorOf element of this mirror. IDs are used
| for inheritance and direct lookup purposes, and must be unique across the set of mirrors.
|
<mirror>
<id>mirrorId</id>
<mirrorOf>repositoryId</mirrorOf>
<name>Human Readable Name for this Mirror.</name>
<url>http://my.repository.com/repo/path</url>
</mirror>
-->
<mirror>
<id>Central</id>
<url>http://repo1.maven.org/maven2</url>
<mirrorOf>central</mirrorOf>
</mirror>
</mirrors>
=====================================settings.xml===================================================
----------------------ERROR log-------------------
Errors occurred during the build.
Errors running builder 'Maven Project Builder' on project '项目名称'.
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
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
-----------------------感谢原作者 http://blog.csdn.net/xuefeng0707/article/details/42157311----------------------
Eclipse创建maven项目时报错:maven-resources-plugin:2.5 or one of its dependencies could not be resolved
Eclipse创建maven简单项目时,报错: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
本人解决方法:
修改settings.xml,添加:
- <mirror>
- <id>Central</id>
- <url>http://repo1.maven.org/maven2</url>
- <mirrorOf>central</mirrorOf>
- </mirror>
而后删除项目重新创建,或者Force Update