Failed to read artifact descriptor for org.apache.maven.plugins:maven-jar-plugin:jar:2.5

来源:互联网 发布:h3c交换机端口加vlan 编辑:程序博客网 时间:2024/06/05 08:19

新建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

原因可能如下:

1.未对maven进行配置。
Window->Preferences->Maven->User Settings->选择maven安装目录,例如:D:\apache\apache-maven-3.0.3\conf\settings.xml

2.上网方式为代理上网,但是没有对maven设置代理。
修改D:\apache\apache-maven-3.0.3\conf\settings.xml
在<proxies></proxies>中间加上:
<proxy>
<id>optional</id>
<active>true</active>
<protocol>http</protocol>
<host>代理的ip地址</host>
<port>端口</port>
</proxy>


原文地址:http://www.zhounenghua.cn/failed-to-read-artifact-descriptor-for-org-apache-maven-pluginsmaven-resources-plugin/

0 0
原创粉丝点击