Skip to content

Commit 9bb7a9b

Browse files
committed
java deploy to central instead of oss
1 parent 5794323 commit 9bb7a9b

2 files changed

Lines changed: 32 additions & 32 deletions

File tree

.github/workflows/build_deploy_java_language_bindings.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
push:
55
branches:
66
- master
7+
- fix/174-java-deploy-central
78
paths:
89
- "models/java/**"
910

@@ -27,15 +28,15 @@ jobs:
2728
OP_SERVICE_ACCOUNT_TOKEN: ${{ secrets.OP_SERVICE_ACCOUNT_TOKEN }} # This is required to connect to the vault in our 1Password account.
2829
MAVEN_GPG_PRIVATE_KEY: "op://rbiv7rvkkrsdlpcrz3bmv7nmcu/dkkfywvsr3xq6eyeubq6cldaxi/Private Key"
2930
MAVEN_GPG_PASSPHRASE: "op://rbiv7rvkkrsdlpcrz3bmv7nmcu/dkkfywvsr3xq6eyeubq6cldaxi/password"
30-
MAVEN_USERNAME: "op://rbiv7rvkkrsdlpcrz3bmv7nmcu/4o43n5uyr7zjog6u2y5i3fjzye/username"
31-
MAVEN_PASSWORD: "op://rbiv7rvkkrsdlpcrz3bmv7nmcu/4o43n5uyr7zjog6u2y5i3fjzye/credential"
31+
MAVEN_USERNAME: "op://rbiv7rvkkrsdlpcrz3bmv7nmcu/Maven Central Portal user token/username"
32+
MAVEN_PASSWORD: "op://rbiv7rvkkrsdlpcrz3bmv7nmcu/Maven Central Portal user token/password"
3233

3334
- name: Set up JDK
3435
uses: actions/setup-java@v4
3536
with:
3637
java-version: '17.0.11'
3738
distribution: 'temurin'
38-
server-id: ossrh
39+
server-id: central
3940
server-username: MAVEN_USERNAME
4041
server-password: MAVEN_PASSWORD
4142
gpg-private-key: ${{ env.MAVEN_GPG_PRIVATE_KEY }}

models/java/gbfs-java-model/pom.xml

Lines changed: 28 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<modelVersion>4.0.0</modelVersion>
66
<groupId>org.mobilitydata</groupId>
77
<artifactId>gbfs-java-model</artifactId>
8-
<version>1.0.10</version>
8+
<version>1.0.11</version>
99

1010
<name>gbfs-java-model</name>
1111

@@ -20,7 +20,7 @@
2020
<name>Apache License, Version 2.0</name>
2121
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
2222
<distribution>repo</distribution>
23-
</license>
23+
</license>
2424
</licenses>
2525
<developers>
2626
<developer>
@@ -44,12 +44,12 @@
4444
</scm>
4545
<distributionManagement>
4646
<snapshotRepository>
47-
<id>ossrh</id>
48-
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
47+
<id>central</id>
48+
<url>https://central.sonatype.com/content/repositories/snapshots/</url>
4949
</snapshotRepository>
5050
<repository>
51-
<id>ossrh</id>
52-
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2</url>
51+
<id>central</id>
52+
<url>https://central.sonatype.com/service/local/staging/deploy/maven2/</url>
5353
</repository>
5454
</distributionManagement>
5555

@@ -61,7 +61,7 @@
6161
<jackson-databind.version>2.17.0</jackson-databind.version>
6262
<geojson-jackson.version>1.14</geojson-jackson.version>
6363

64-
<nexus-staging-maven-plugin.version>1.6.13</nexus-staging-maven-plugin.version>
64+
<central-publishing-maven-plugin.version>0.9.0</central-publishing-maven-plugin.version>
6565
<jacoco-maven-plugin.version>0.8.12</jacoco-maven-plugin.version>
6666
<maven-exec-plugin.version>1.6.0</maven-exec-plugin.version>
6767
<maven-surefire-plugin.version>2.22.2</maven-surefire-plugin.version>
@@ -376,14 +376,13 @@
376376
</executions>
377377
</plugin>
378378
<plugin>
379-
<groupId>org.sonatype.plugins</groupId>
380-
<artifactId>nexus-staging-maven-plugin</artifactId>
381-
<version>${nexus-staging-maven-plugin.version}</version>
379+
<groupId>org.sonatype.central</groupId>
380+
<artifactId>central-publishing-maven-plugin</artifactId>
381+
<version>${central-publishing-maven-plugin.version}</version>
382382
<extensions>true</extensions>
383383
<configuration>
384-
<serverId>ossrh</serverId>
385-
<nexusUrl>https://s01.oss.sonatype.org</nexusUrl>
386-
<autoReleaseAfterClose>true</autoReleaseAfterClose>
384+
<publishingServerId>central</publishingServerId>
385+
<autoPublish>true</autoPublish>
387386
</configuration>
388387
</plugin>
389388
<plugin>
@@ -412,12 +411,12 @@
412411
</activation>
413412
<distributionManagement>
414413
<snapshotRepository>
415-
<id>ossrh</id>
416-
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
414+
<id>central</id>
415+
<url>https://central.sonatype.com/content/repositories/snapshots/</url>
417416
</snapshotRepository>
418417
<repository>
419-
<id>ossrh</id>
420-
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2</url>
418+
<id>central</id>
419+
<url>https://central.sonatype.com/service/local/staging/deploy/maven2/</url>
421420
</repository>
422421
</distributionManagement>
423422
<build>
@@ -434,7 +433,8 @@
434433
<goal>sign</goal>
435434
</goals>
436435
<configuration>
437-
<!-- Prevent gpg from using pinentry programs. Fixes: gpg: signing
436+
<!-- Prevent gpg from using pinentry programs. Fixes: gpg:
437+
signing
438438
failed: Inappropriate ioctl for device -->
439439
<passphrase>${env.MAVEN_GPG_PASSPHRASE}</passphrase>
440440
<gpgArguments>
@@ -455,12 +455,12 @@
455455
</activation>
456456
<distributionManagement>
457457
<snapshotRepository>
458-
<id>ossrh</id>
459-
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
458+
<id>central</id>
459+
<url>https://central.sonatype.com/content/repositories/snapshots/</url>
460460
</snapshotRepository>
461461
<repository>
462-
<id>ossrh</id>
463-
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2</url>
462+
<id>central</id>
463+
<url>https://central.sonatype.com/service/local/staging/deploy/maven2/</url>
464464
</repository>
465465
</distributionManagement>
466466
<build>
@@ -487,18 +487,17 @@
487487
</executions>
488488
</plugin>
489489
<plugin>
490-
<groupId>org.sonatype.plugins</groupId>
491-
<artifactId>nexus-staging-maven-plugin</artifactId>
490+
<groupId>org.sonatype.central</groupId>
491+
<artifactId>central-publishing-maven-plugin</artifactId>
492+
<version>${central-publishing-maven-plugin.version}</version>
492493
<extensions>true</extensions>
493494
<configuration>
494-
<serverId>ossrh</serverId>
495-
<nexusUrl>https://s01.oss.sonatype.org</nexusUrl>
496-
<!-- Set this to true and the release will automatically proceed and sync to Central Repository will follow -->
497-
<autoReleaseAfterClose>true</autoReleaseAfterClose>
495+
<publishingServerId>central</publishingServerId>
496+
<autoPublish>true</autoPublish>
498497
</configuration>
499498
</plugin>
500499
</plugins>
501500
</build>
502501
</profile>
503502
</profiles>
504-
</project>
503+
</project>

0 commit comments

Comments
 (0)