maven下载依赖jar包的时候特别慢,而且会断,一直要update project...
解决maven下载依赖慢的问题:
就是换成aliyun的镜像就可以了。
将下面的内容保存为setting.xml
<?xml version="1.0" encoding="UTF-8"?>"http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd"> /Users/xxx/.m2/repository
nexus-aliyun central Nexus aliyun http://maven.aliyun.com/nexus/content/groups/public
然后apply,如果下面的LocalRepository跟你的电脑一致就可以了,如果路径不对,调整为自己的位置。
然后再次:Update Project ... ,会发现这个速度是快及了。
不一会儿就成功了,走的是aliyun的服务器。
参考:https://blog.csdn.net/qq_38163755/article/details/105998602