gpt4 book ai didi

eclipse - Maven 错误 "Failure to transfer..."

转载 作者:行者123 更新时间:2023-12-04 00:44:20 25 4
gpt4 key购买 nike

我正在尝试使用 Maven (m2eclipse) 设置项目,但在 Eclipse 中出现此错误:

Description Resource Path Location Type Could not calculate build plan: Failure to transfer org.apache.maven.plugins:maven-compiler-plugin:pom:2.0.2 from http://repo1.maven.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced. Original error: Could not transfer artifact org.apache.maven.plugins:maven-compiler-plugin:pom:2.0.2 from/to central (http://repo1.maven.org/maven2): No response received after 60000 ExampleProject Unknown Maven Problem



有任何想法吗?
如果您能告诉我如何检查一切是否配置正常,那将会很有帮助...

最佳答案

删除所有失败的下载:

find ~/.m2  -name "*.lastUpdated" -exec grep -q "Could not transfer" {} \; -print -exec rm {} \;

对于 window :
cd %userprofile%\.m2\repository
for /r %i in (*.lastUpdated) do del %i

然后在 Eclipse 中右键单击您的项目并选择 Maven->“更新项目...”,确保在结果对话框中选中“更新依赖项”并单击“确定”。

关于eclipse - Maven 错误 "Failure to transfer...",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5074063/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com