Skip to content

Commit 2625725

Browse files
committed
Add nexus-staging plugin to "plugins" section
Before this change, running "mvn deploy" would result in running the "maven-deploy-plugin:deploy" goal. This behavior differs from Java Driver 4.x, which executes a "nexus-staging-maven-plugin:deploy" goal. This change should fix auto-closing of Sonatype repository when releasing the driver, as is already done in Java Driver 4.x. This will make it easier in the future to automate the release of Java Driver 3.x, as a maintainer won't have to manually close Sonetype repository through a website.
1 parent f5fc83d commit 2625725

File tree

2 files changed

+21
-7
lines changed

2 files changed

+21
-7
lines changed

driver-dist/pom.xml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,14 @@
100100
</configuration>
101101
</plugin>
102102

103+
<plugin>
104+
<groupId>org.sonatype.plugins</groupId>
105+
<artifactId>nexus-staging-maven-plugin</artifactId>
106+
<configuration>
107+
<skipNexusStagingDeployMojo>true</skipNexusStagingDeployMojo>
108+
</configuration>
109+
</plugin>
110+
103111
</plugins>
104112

105113
</build>
@@ -144,13 +152,6 @@
144152
<tarLongFileMode>posix</tarLongFileMode>
145153
</configuration>
146154
</plugin>
147-
<plugin>
148-
<groupId>org.sonatype.plugins</groupId>
149-
<artifactId>nexus-staging-maven-plugin</artifactId>
150-
<configuration>
151-
<skipNexusStagingDeployMojo>true</skipNexusStagingDeployMojo>
152-
</configuration>
153-
</plugin>
154155
</plugins>
155156
</build>
156157
</profile>

pom.xml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -924,6 +924,19 @@
924924
<artifactId>clirr-maven-plugin</artifactId>
925925
</plugin>
926926

927+
<plugin>
928+
<groupId>org.sonatype.plugins</groupId>
929+
<artifactId>nexus-staging-maven-plugin</artifactId>
930+
<version>1.6.8</version>
931+
<extensions>true</extensions>
932+
<configuration>
933+
<serverId>ossrh</serverId>
934+
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
935+
<autoReleaseAfterClose>true</autoReleaseAfterClose>
936+
<!-- skipLocalStaging>true</skipLocalStaging -->
937+
</configuration>
938+
</plugin>
939+
927940
</plugins>
928941

929942
</build>

0 commit comments

Comments
 (0)