我正在开发一个位于私人公司 GitLab 存储库中的 Java 库。它是供客户使用的 SDK 的一部分。我正在尝试弄清楚如何将其发布到 Maven Central,但我一直在 pom.xml 中设置 SCM 字段。
当存储库不公开时,我该如何设置这些字段?
我需要这样的东西:
<!-- Define where the source code for this project lives -->
<scm>
<connection>scm:git:https://github.com/evansiroky/maven-semantic-release-example.git</connection>
<developerConnection>scm:git:https://github.com/evansiroky/maven-semantic-release-example.git</developerConnection>
<url>https://github.com/evansiroky/maven-semantic-release-example</url>
</scm>
SCM 字段可以指向私有存储库,URL 可以指向网站。
我最终这样做了:
<scm>
<connection>scm:git:https://private-repo.com/private-repo.git</connection>
<developerConnection>scm:git:https://private-repo.com/private-repo.git</developerConnection>
<url>https://docs.mywebsite.com</url>
</scm>