Skip to content

Commit af1b1f1

Browse files
cpovirkGoogle Java Core Libraries
authored andcommitted
Migrate to central-publishing-maven-plugin.
This is like cl/782079419 but for our other projects. (Specifically, I covered Guava and all the projects with `pom.xml` files that I'm used to updating for a new Guava release. I haven't tried to find any projects we run _without_ Guava dependencies (if any) or any that use Bazel instead of Maven.) As in the previous CL, I have updated the GitHub CI repository secrets as described in https://central.sonatype.org/publish/generate-portal-token/, **but** I have done so only for projects where I have deployment permission (specifically, Compile-Testing, Guava, and Truth). The others (Auto and Caliper) will need to be updated by someone who has publication permission for those projects. (Actually, it looks like Caliper doesn't actually deploy CI snapshots, even though it seems to have Sonatype credentials saved in GitHub. Hmm.) And CI snapshot releases aside, anyone who wants to deploy a "true" release will need to enter a token into `~/.m2/settings.xml`, again as discussed in cl/782079419. RELNOTES=n/a PiperOrigin-RevId: 786033817
1 parent c603124 commit af1b1f1

2 files changed

Lines changed: 20 additions & 14 deletions

File tree

factory/pom.xml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -89,14 +89,8 @@
8989
<distributionManagement>
9090
<snapshotRepository>
9191
<id>sonatype-nexus-snapshots</id>
92-
<name>Sonatype Nexus Snapshots</name>
93-
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
92+
<url>https://central.sonatype.com/repository/maven-snapshots/</url>
9493
</snapshotRepository>
95-
<repository>
96-
<id>sonatype-nexus-staging</id>
97-
<name>Nexus Release Repository</name>
98-
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
99-
</repository>
10094
</distributionManagement>
10195

10296
<dependencies>
@@ -317,6 +311,15 @@
317311
</execution>
318312
</executions>
319313
</plugin>
314+
<plugin>
315+
<groupId>org.sonatype.central</groupId>
316+
<artifactId>central-publishing-maven-plugin</artifactId>
317+
<version>0.8.0</version>
318+
<extensions>true</extensions>
319+
<configuration>
320+
<publishingServerId>central</publishingServerId>
321+
</configuration>
322+
</plugin>
320323
</plugins>
321324
</build>
322325
</profile>

value/pom.xml

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -83,14 +83,8 @@
8383
<distributionManagement>
8484
<snapshotRepository>
8585
<id>sonatype-nexus-snapshots</id>
86-
<name>Sonatype Nexus Snapshots</name>
87-
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
86+
<url>https://central.sonatype.com/repository/maven-snapshots/</url>
8887
</snapshotRepository>
89-
<repository>
90-
<id>sonatype-nexus-staging</id>
91-
<name>Nexus Release Repository</name>
92-
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
93-
</repository>
9488
</distributionManagement>
9589

9690
<dependencyManagement>
@@ -279,6 +273,15 @@
279273
</execution>
280274
</executions>
281275
</plugin>
276+
<plugin>
277+
<groupId>org.sonatype.central</groupId>
278+
<artifactId>central-publishing-maven-plugin</artifactId>
279+
<version>0.8.0</version>
280+
<extensions>true</extensions>
281+
<configuration>
282+
<publishingServerId>central</publishingServerId>
283+
</configuration>
284+
</plugin>
282285
</plugins>
283286
</build>
284287
</profile>

0 commit comments

Comments
 (0)