Maven修改默认仓库为阿里云仓库
2023-09-27 14:19:56 时间
Maven修改默认仓库为阿里云仓库
Maven 仓库默认在国外, 国内使用难免很慢,我们可以更换为阿里云的仓库。
第一步:修改 maven 根目录下的 conf 文件夹中的 setting.xml 文件,在 mirrors 节点上,添加内容如下:
<mirrors>
<mirror>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
<mirrorOf>central</mirrorOf>
</mirror>
</mirrors>
第二步: pom.xml文件里添加:
<repositories>
<repository>
<id>alimaven</id>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
原文地址:https://www.cnblogs.com/ttty/p/10307770.html
相关文章
- 关于mac上的maven
- Maven-搭建maven web项目
- Maven无法下载com.oracle:ojdbc14:jar解决方法
- Failure to transfer org.apache.maven.plugins:maven-surefire-plugin:pom:2.22.2 from https://repo.maven.apache.org/maven2 was cached in the local repository
- Maven Eclipse各种操作
- maven 打包Could not resolve dependencies for project和无效的目标发行版: 1.8
- from: Maven实战(九)——打包的技巧
- 阿里云Maven仓库地址setting配置
- maven 项目报错org.apache.ibatis.binding.BindingException: Invalid bound statement (not found)解决
- 阿里云服务端SDK下载的jar包通过maven命令安装(maven手动安装本地jar包到项目)
- [Maven进阶]私服
- [Maven进阶]聚合和继承
- 已解决IDEA创建Maven项目出现:“role: org.apache.maven.model.validation.ModelValidator roleHint: ide”
- 设备MyEclipse6.5的maven
- IDEA中设置maven阿里云镜像
- Android配置maven阿里云镜像
- 阿里私服 maven 配置settings.xml