Skip to content

Commit

Permalink
Migrate to central-publishing-maven-plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
tzolov committed Jan 28, 2025
1 parent 1a506d0 commit c78c1ad
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 31 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/continuous-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
java-version: '17'
distribution: 'temurin'
cache: 'maven'
server-id: ossrh
server-id: central
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
gpg-private-key: ${{ secrets.GPG_SECRET_KEY }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/maven-central-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
java-version: '17'
distribution: 'temurin'
cache: 'maven'
server-id: ossrh
server-id: central
server-username: MAVEN_USERNAME
server-password: MAVEN_PASSWORD
gpg-private-key: ${{ secrets.GPG_SECRET_KEY }}
Expand Down
35 changes: 6 additions & 29 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,6 @@
<system>Github Actions</system>
<url>https://github.com/modelcontextprotocol/java-sdk/actions</url>
</ciManagement>
<distributionManagement>
<repository>
<id>ossrh</id>
<name>Central Repository OSSRH</name>
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand Down Expand Up @@ -300,19 +293,13 @@
<build>
<plugins>
<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.7.0</version>
<groupId>org.sonatype.central</groupId>
<artifactId>central-publishing-maven-plugin</artifactId>
<version>0.7.0</version>
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
<nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
<!--
the property autoReleaseAfterClose set to false you can manually inspect the staging repository in
the Nexus Repository Manager and trigger a release of the staging
repository later
-->
<autoReleaseAfterClose>false</autoReleaseAfterClose>
<publishingServerId>central</publishingServerId>
<autoPublish>false</autoPublish>
</configuration>
</plugin>
<plugin>
Expand All @@ -338,16 +325,6 @@
</plugin>
</plugins>
</build>
<distributionManagement>
<snapshotRepository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
</snapshotRepository>
<repository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>
</profile>
</profiles>

Expand Down Expand Up @@ -385,4 +362,4 @@
</repository>
</repositories>

</project>
</project>

0 comments on commit c78c1ad

Please sign in to comment.