Skip to content

Commit 534a4b1

Browse files
committed
Merge remote-tracking branch 'origin/update-from-template'
2 parents 6ac1558 + a0c76bc commit 534a4b1

File tree

3 files changed

+19
-56
lines changed

3 files changed

+19
-56
lines changed

.github/workflows/release.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -124,22 +124,22 @@ jobs:
124124
git config --global user.name "GitHub Actions"
125125
git pull
126126
127-
- name: Set up JDK OSSRH
127+
- name: Set up JDK
128128
uses: actions/setup-java@v4
129129
with: # running setup-java again overwrites the settings.xml
130130
java-version: '17'
131131
distribution: 'temurin'
132-
server-id: ossrh
132+
server-id: sonatype-central-portal
133133
server-username: MAVEN_CENTRAL_USERNAME
134134
server-password: MAVEN_CENTRAL_TOKEN
135135
gpg-passphrase: MAVEN_GPG_PASSPHRASE
136136
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }}
137137

138-
- name: Publish to OSSRH
139-
run: ../mvnw -B deploy -Possrh -DskipTests
138+
- name: Publish to Central Portal
139+
run: ../mvnw -B deploy -P publish-sonatype-central-portal -DskipTests
140140
env:
141-
MAVEN_CENTRAL_USERNAME: ${{ secrets.S01_OSS_SONATYPE_MAVEN_USERNAME }}
142-
MAVEN_CENTRAL_TOKEN: ${{ secrets.S01_OSS_SONATYPE_MAVEN_TOKEN }}
141+
MAVEN_CENTRAL_USERNAME: ${{ secrets.SONATYPE_MAVEN_CENTRAL_PORTAL_USERNAME }}
142+
MAVEN_CENTRAL_TOKEN: ${{ secrets.SONATYPE_MAVEN_CENTRAL_PORTAL_TOKEN }}
143143
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}
144144
working-directory: ${{ env.PRIMARY_MAVEN_MODULE }}
145145

.github/workflows/test-deploy.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,21 @@ jobs:
1313
steps:
1414
- uses: actions/checkout@v4
1515

16-
- name: Set up JDK OSSRH
16+
- name: Set up JDK
1717
uses: actions/setup-java@v4
1818
with: # running setup-java again overwrites the settings.xml
1919
distribution: 'temurin'
2020
java-version: '17'
21-
server-id: ossrh
21+
server-id: sonatype-central-portal
2222
server-username: MAVEN_CENTRAL_USERNAME
2323
server-password: MAVEN_CENTRAL_TOKEN
2424
gpg-passphrase: MAVEN_GPG_PASSPHRASE
2525
gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }}
2626

27-
- name: Publish to OSSRH
28-
run: ../mvnw -B deploy -Possrh -DskipTests
27+
- name: Publish to Central Portal
28+
run: ../mvnw -B deploy -P publish-sonatype-central-portal -DskipTests
2929
working-directory: ${{ env.PRIMARY_MAVEN_MODULE }}
3030
env:
31-
MAVEN_CENTRAL_USERNAME: ${{ secrets.S01_OSS_SONATYPE_MAVEN_USERNAME }}
32-
MAVEN_CENTRAL_TOKEN: ${{ secrets.S01_OSS_SONATYPE_MAVEN_TOKEN }}
31+
MAVEN_CENTRAL_USERNAME: ${{ secrets.SONATYPE_MAVEN_CENTRAL_PORTAL_USERNAME }}
32+
MAVEN_CENTRAL_TOKEN: ${{ secrets.SONATYPE_MAVEN_CENTRAL_PORTAL_TOKEN }}
3333
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}

template-placeholder/pom.xml

Lines changed: 7 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -64,41 +64,6 @@
6464
</dependencies>
6565
</dependencyManagement>
6666

67-
<repositories>
68-
<!-- The order of definitions matters. Explicitly defining central here
69-
to make sure it has the highest priority. -->
70-
<repository>
71-
<id>central</id>
72-
<url>https://repo.maven.apache.org/maven2</url>
73-
<snapshots>
74-
<enabled>false</enabled>
75-
</snapshots>
76-
</repository>
77-
</repositories>
78-
79-
<pluginRepositories>
80-
<!-- The order of definitions matters. Explicitly defining central here
81-
to make sure it has the highest priority. -->
82-
<pluginRepository>
83-
<id>central</id>
84-
<url>https://repo.maven.apache.org/maven2</url>
85-
<snapshots>
86-
<enabled>false</enabled>
87-
</snapshots>
88-
</pluginRepository>
89-
</pluginRepositories>
90-
91-
<distributionManagement>
92-
<snapshotRepository>
93-
<id>ossrh</id>
94-
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
95-
</snapshotRepository>
96-
<repository>
97-
<id>ossrh</id>
98-
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
99-
</repository>
100-
</distributionManagement>
101-
10267
<dependencies>
10368
<dependency>
10469
<groupId>com.vaadin</groupId>
@@ -237,7 +202,7 @@
237202
</build>
238203
<profiles>
239204
<profile>
240-
<id>ossrh</id>
205+
<id>publish-sonatype-central-portal</id>
241206
<build>
242207
<plugins>
243208
<plugin>
@@ -281,16 +246,14 @@
281246
</plugin>
282247

283248
<plugin>
284-
<groupId>org.sonatype.plugins</groupId>
285-
<artifactId>nexus-staging-maven-plugin</artifactId>
286-
<version>1.7.0</version>
249+
<groupId>org.sonatype.central</groupId>
250+
<artifactId>central-publishing-maven-plugin</artifactId>
251+
<version>0.7.0</version>
287252
<extensions>true</extensions>
288253
<configuration>
289-
<serverId>ossrh</serverId>
290-
<nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
291-
<!-- Sometimes OSSRH is really slow -->
292-
<stagingProgressTimeoutMinutes>30</stagingProgressTimeoutMinutes>
293-
<autoReleaseAfterClose>true</autoReleaseAfterClose>
254+
<publishingServerId>sonatype-central-portal</publishingServerId>
255+
<autoPublish>true</autoPublish>
256+
<waitUntil>published</waitUntil>
294257
</configuration>
295258
</plugin>
296259
</plugins>

0 commit comments

Comments
 (0)