目录
一、Windows安装nexus
1、下载地址:
https://blog.csdn.net/yx5131421/article/details/125616477
2、启动并设置密码
在bin目录下,使用命令nexus.exe /run
在浏览器访问:http://localhost:8081/
并设置密码
二、配置maven的settings.xml 文件
servers>
<server>
<id>anhao-releases</id>
<username>admin</username>
<password>123456</password>
</server>
<server>
<id>anhao-snapshots</id>
<username>admin</username>
<password>123456</password>
</server>
</servers>
三、配置maven项目的pom
<distributionManagement>
<repository>
<id>anhao-releases</id>
<name>release</name>
<url>http://localhost:8081/repository/maven-releases/</url>
</repository>
<snapshotRepository>
<id>anhao-snapshots</id>
<name>snapshot</name>
<url>http://localhost:8081/repository/maven-snapshots/</url>
</snapshotRepository>
</distributionManagement>
四、查看是否上传成功