nexus中上传了第三方jar包,在本地项目中添加了引用,但就是下载不下来。
问题描述在nexus中上传了第三方jar包,在本地项目中添加了引用,但就是下载不下来。
转载文章
1. 打开windows -> preferences -> maven,勾选如图所示
2. 打开 windows -> show views -> orther -> maven -> maven repositories 视图
3. 在maven repositories 视图中的全局repositories 上右键,选择Update index
4. 下载时eclipse可能有点慢,等几分钟就会下载最新的包了。
经常出现的问题:
Unable to update index for central|http
To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
......
快速解决方案:
找到setting里的远程地址(或在maven repositories 视图中的全局repositories 上找到Gloable repositories里的相关地址),直接在浏览器里打开地址下载,并在本地建立相关文件夹放入下载的jar包。