Skip to content

Commit 60c8cd4

Browse files
committed
Migration to Central Publisher Portal
1 parent 0bcf677 commit 60c8cd4

1 file changed

Lines changed: 27 additions & 12 deletions

File tree

pom.xml

Lines changed: 27 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -166,18 +166,7 @@
166166
</issueManagement>
167167

168168
<distributionManagement>
169-
<!-- https://docs.github.com/en/actions/guides/publishing-java-packages-with-maven#publishing-packages-to-the-maven-central-repository -->
170-
<!-- https://blog.sonatype.com/what-publishers-need-to-know-about-migrating-from-jcenter-/-bintray-to-the-central-repository -->
171-
<!-- New: Publishing directly to Sonatype OSSRH (OSS Repository Hosting), for release to Maven Central -->
172-
<!-- URLs available from: https://central.sonatype.org/pages/ossrh-guide.html#accessing-repositories -->
173-
<snapshotRepository>
174-
<id>ossrh</id>
175-
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
176-
</snapshotRepository>
177-
<repository>
178-
<id>ossrh</id>
179-
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
180-
</repository>
169+
<!-- According to the documentation https://central.sonatype.org/publish/publish-portal-maven/, it is no longer necessary to configure a repository -->
181170
</distributionManagement>
182171

183172

@@ -240,8 +229,34 @@
240229
<releaseProfiles>run-release</releaseProfiles>
241230
<!-- Disable pushing of changes (i.e. false, for local testing) -->
242231
<pushChanges>false</pushChanges>
232+
<!-- NEW: Disable deployment during release:perform -->
233+
<goals>deploy</goals>
243234
</configuration>
244235
</plugin>
236+
<!-- NEW: Disable the old maven-deploy-plugin -->
237+
<plugin>
238+
<groupId>org.apache.maven.plugins</groupId>
239+
<artifactId>maven-deploy-plugin</artifactId>
240+
<configuration>
241+
<skip>true</skip>
242+
</configuration>
243+
</plugin>
244+
<!-- NEW: Plugin for publishing to Maven Central -->
245+
<plugin>
246+
<groupId>org.sonatype.central</groupId>
247+
<artifactId>central-publishing-maven-plugin</artifactId>
248+
<version>0.9.0</version>
249+
<extensions>true</extensions>
250+
<configuration>
251+
<publishingServerId>central</publishingServerId>
252+
<!-- Automatic publication after validation -->
253+
<autoPublish>true</autoPublish>
254+
<!-- Wait until the publication is effective -->
255+
<waitUntil>published</waitUntil>
256+
<!-- Readable name to identify the deployment -->
257+
<deploymentName>${project.artifactId}-${project.version}</deploymentName>
258+
</configuration>
259+
</plugin>
245260
<plugin>
246261
<groupId>org.apache.maven.plugins</groupId>
247262
<artifactId>maven-resources-plugin</artifactId>

0 commit comments

Comments
 (0)