POM.xml文件中添加:
<distributionManagement>
<repository>
<id>footstee</id>
<name>Internal Releases</name>
<url>http://localhost:8081/nexus/content/repositories/thirdparty</url>
</repository>
</distributionManagement>
Setting.xml中添加:
<server>
<id>footstee</id>
<username>repouser</username>
<password>repopwd</password>
</server>
关键:id必须一致
接下来使用 maven deploy命令,可以将项目打包上传到远程仓库。
eclipse中可以新建maven命令执行deploy