Skip to content

Commit 69452aa

Browse files
feat: migrate to new Maven Central publish
Signed-off-by: Mario Serrano <mario@dynamiasoluciones.com>
1 parent fc0ced6 commit 69452aa

File tree

3 files changed

+8
-19
lines changed

3 files changed

+8
-19
lines changed

.github/workflows/maven.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313

1414
steps:
1515
- uses: actions/checkout@v3
16-
- name: Set up JDK 17
16+
- name: Set up JDK 21
1717
uses: actions/setup-java@v3
1818
with:
1919
java-version: 21

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,14 @@ jobs:
1515

1616
steps:
1717
- uses: actions/checkout@v4
18-
- name: Set up JDK 17
18+
- name: Set up JDK 21
1919
uses: actions/setup-java@v4
2020
with:
2121
java-version: 21
2222
architecture: x64
2323
distribution: temurin
2424
cache: maven
25-
server-id: ossrh
25+
server-id: central
2626
server-username: MAVEN_USERNAME # env variable for username in deploy
2727
server-password: MAVEN_PASSWORD # env variable for token in deploy
2828
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}

sources/pom.xml

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -93,14 +93,13 @@
9393
</configuration>
9494
</plugin>
9595
<plugin>
96-
<groupId>org.sonatype.plugins</groupId>
97-
<artifactId>nexus-staging-maven-plugin</artifactId>
98-
<version>1.7.0</version>
96+
<groupId>org.sonatype.central</groupId>
97+
<artifactId>central-publishing-maven-plugin</artifactId>
98+
<version>0.8.0</version>
9999
<extensions>true</extensions>
100100
<configuration>
101-
<serverId>ossrh</serverId>
102-
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
103-
<autoReleaseAfterClose>true</autoReleaseAfterClose>
101+
<publishingServerId>central</publishingServerId>
102+
<autoPublish>true</autoPublish>
104103
</configuration>
105104
</plugin>
106105
<plugin>
@@ -121,16 +120,6 @@
121120
</build>
122121

123122

124-
<distributionManagement>
125-
<snapshotRepository>
126-
<id>ossrh</id>
127-
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
128-
</snapshotRepository>
129-
<repository>
130-
<id>ossrh</id>
131-
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
132-
</repository>
133-
</distributionManagement>
134123

135124
<profiles>
136125
<profile>

0 commit comments

Comments
 (0)