Skip to content

Commit 406ce24

Browse files
authored
Merge pull request #861 from hazendaz/master
Update actions and prepare for central
2 parents dcf4ef4 + 42fa88f commit 406ce24

File tree

5 files changed

+29
-33
lines changed

5 files changed

+29
-33
lines changed

.github/workflows/ci.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
matrix:
1010
cache: [maven]
1111
distribution: [temurin]
12-
java: [17, 21, 23, 24-ea, 25-ea]
12+
java: [17, 21, 24, 25-ea]
1313
os: [ubuntu-latest, macos-latest, windows-latest]
1414
fail-fast: false
1515
max-parallel: 4

.github/workflows/site.yaml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ on:
55
branches:
66
- site
77

8+
permissions:
9+
contents: write
10+
811
jobs:
912
build:
1013
if: github.repository_owner == 'mybatis' && ! contains(toJSON(github.event.head_commit.message), '[maven-release-plugin]')
@@ -20,12 +23,10 @@ jobs:
2023
- name: Build site
2124
run: ./mvnw site site:stage -DskipTests -Dlicense.skip=true -B -V --no-transfer-progress --settings ./.mvn/settings.xml
2225
env:
23-
CI_DEPLOY_USERNAME: ${{ secrets.CI_DEPLOY_USERNAME }}
2426
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2527
NVD_API_KEY: ${{ secrets.NVD_API_KEY }}
2628
- name: Deploy Site to gh-pages
2729
uses: JamesIves/github-pages-deploy-action@v4
2830
with:
2931
branch: gh-pages
3032
folder: target/staging
31-
ssh-key: ${{ secrets.DEPLOY_KEY }}

.mvn/extensions.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,6 @@
2020
<extension>
2121
<groupId>fr.jcgay.maven</groupId>
2222
<artifactId>maven-profiler</artifactId>
23-
<version>3.2</version>
23+
<version>3.3</version>
2424
</extension>
2525
</extensions>

.mvn/settings.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<servers>
2323
<!-- Used for sonatype snapshots and releases -->
2424
<server>
25-
<id>ossrh</id>
25+
<id>central</id>
2626
<username>${env.CI_DEPLOY_USERNAME}</username>
2727
<password>${env.CI_DEPLOY_PASSWORD}</password>
2828
</server>
@@ -39,7 +39,6 @@
3939
<!-- Github deployments (site) -->
4040
<server>
4141
<id>github</id>
42-
<username>${env.CI_DEPLOY_USERNAME}</username>
4342
<password>${env.GITHUB_TOKEN}</password>
4443
</server>
4544

pom.xml

Lines changed: 23 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -245,13 +245,9 @@
245245
<url>https://github.com/mybatis/parent/actions</url>
246246
</ciManagement>
247247
<distributionManagement>
248-
<repository>
249-
<id>ossrh</id>
250-
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
251-
</repository>
252248
<snapshotRepository>
253-
<id>ossrh</id>
254-
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
249+
<id>central</id>
250+
<url>https://central.sonatype.com/repository/maven-snapshots/</url>
255251
</snapshotRepository>
256252
<site>
257253
<id>gh-pages-scm</id>
@@ -345,7 +341,6 @@
345341
<license.plugin>5.0.0</license.plugin>
346342
<lifecycle.plugin>1.0.0</lifecycle.plugin>
347343
<modernizer.plugin>3.1.0</modernizer.plugin>
348-
<pdf.plugin>1.6.2</pdf.plugin>
349344
<pmd.plugin>3.26.0</pmd.plugin>
350345
<project-info.plugin>3.9.0</project-info.plugin>
351346
<release.plugin>3.1.1</release.plugin>
@@ -712,25 +707,6 @@
712707
<version>${jxr.plugin}</version>
713708
</plugin>
714709

715-
<plugin>
716-
<groupId>org.apache.maven.plugins</groupId>
717-
<artifactId>maven-pdf-plugin</artifactId>
718-
<version>${pdf.plugin}</version>
719-
<!-- Execution such as this in plugin management requires plugin definition in build to work -->
720-
<executions>
721-
<execution>
722-
<id>pdf</id>
723-
<goals>
724-
<goal>pdf</goal>
725-
</goals>
726-
<phase>prepare-package</phase>
727-
<configuration>
728-
<includeReports>false</includeReports>
729-
</configuration>
730-
</execution>
731-
</executions>
732-
</plugin>
733-
734710
<plugin>
735711
<groupId>org.apache.maven.plugins</groupId>
736712
<artifactId>maven-pmd-plugin</artifactId>
@@ -898,7 +874,6 @@
898874
<artifactId>modernizer-maven-plugin</artifactId>
899875
<version>${modernizer.plugin}</version>
900876
<configuration>
901-
<failOnViolations>false</failOnViolations>
902877
<javaVersion>${maven.compiler.target}</javaVersion>
903878
</configuration>
904879
<dependencies>
@@ -915,6 +890,17 @@
915890
<artifactId>rewrite-maven-plugin</artifactId>
916891
<version>${rewrite.plugin}</version>
917892
</plugin>
893+
894+
<!-- Sonatype Provided Plugins -->
895+
<plugin>
896+
<groupId>org.sonatype.central</groupId>
897+
<artifactId>central-publishing-maven-plugin</artifactId>
898+
<version>0.7.0</version>
899+
<extensions>true</extensions>
900+
<configuration>
901+
<publishingServerId>central</publishingServerId>
902+
</configuration>
903+
</plugin>
918904
</plugins>
919905
</pluginManagement>
920906

@@ -1024,6 +1010,16 @@
10241010
</execution>
10251011
</executions>
10261012
</plugin>
1013+
1014+
<!-- Sonatype Provided Plugins -->
1015+
<plugin>
1016+
<groupId>org.sonatype.central</groupId>
1017+
<artifactId>central-publishing-maven-plugin</artifactId>
1018+
<extensions>true</extensions>
1019+
<configuration>
1020+
<publishingServerId>central</publishingServerId>
1021+
</configuration>
1022+
</plugin>
10271023
</plugins>
10281024
</build>
10291025

0 commit comments

Comments
 (0)