maven的pom报plugins错误的解决方法.

来源:互联网 发布:假面骑士腰带淘宝 编辑:程序博客网 时间:2024/06/18 18:17
引用
Failure to transferorg.apache.maven.plugins:maven-surefire-plugin:pom:2.7.1 fromhttp://repo1.maven.org/maven2 was cached in the local repository,resolution will not be reattempted until the update interval ofcentral has elapsed or updates are forced

碰到一个类似以上的错误.

原因是maven的plugin并未下载到本地.

网上找了很多资料,说只有一个.lastUpdated 结尾的文件,没有.jar结尾的文件.我照着试了一下.没啥卵用

下面是我的解决方法:

1.在eclipse里找到配置maven仓库的选项,选择配置setting文件的选项.

2.重新选择setting文件的位置,完成后点击update setting按钮.如果出现警告语句产生,说明你的setting文件里面有问题,你需要把你的setting文件替换一个新的;如果没有警告语句产生,那就接着点击apply,确定下去.

3.接着在进行maven的update project操作

4.完美,问题成功解决!


原创粉丝点击