From 08be521289fd77bdcac3f8c4d20756331f4f941c Mon Sep 17 00:00:00 2001 From: XDEV Renovate Bot Date: Sat, 28 Jun 2025 04:14:51 +0000 Subject: [PATCH 1/5] Update net.sourceforge.pmd to v7.15.0 --- pom.xml | 4 ++-- template-placeholder/pom.xml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pom.xml b/pom.xml index 426a852..f4358f3 100644 --- a/pom.xml +++ b/pom.xml @@ -82,12 +82,12 @@ net.sourceforge.pmd pmd-core - 7.14.0 + 7.15.0 net.sourceforge.pmd pmd-java - 7.14.0 + 7.15.0 diff --git a/template-placeholder/pom.xml b/template-placeholder/pom.xml index 876b7a7..d16c327 100644 --- a/template-placeholder/pom.xml +++ b/template-placeholder/pom.xml @@ -246,12 +246,12 @@ net.sourceforge.pmd pmd-core - 7.14.0 + 7.15.0 net.sourceforge.pmd pmd-java - 7.14.0 + 7.15.0 From a166186c6a877be931658117fda66ae7bf34a76b Mon Sep 17 00:00:00 2001 From: XDEV Renovate Bot Date: Mon, 30 Jun 2025 04:24:59 +0000 Subject: [PATCH 2/5] Update dependency com.puppycrawl.tools:checkstyle to v10.26.1 --- pom.xml | 2 +- template-placeholder/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pom.xml b/pom.xml index 426a852..862831e 100644 --- a/pom.xml +++ b/pom.xml @@ -45,7 +45,7 @@ com.puppycrawl.tools checkstyle - 10.26.0 + 10.26.1 diff --git a/template-placeholder/pom.xml b/template-placeholder/pom.xml index 876b7a7..adf5e1e 100644 --- a/template-placeholder/pom.xml +++ b/template-placeholder/pom.xml @@ -209,7 +209,7 @@ com.puppycrawl.tools checkstyle - 10.26.0 + 10.26.1 From c6e807f728ad34a6e531a43be9423092f72a9398 Mon Sep 17 00:00:00 2001 From: Alex B <45384811+AB-xdev@users.noreply.github.com> Date: Tue, 1 Jul 2025 10:50:39 +0200 Subject: [PATCH 3/5] Simplify: Use ``processAllModules`` flag --- .github/workflows/release.yml | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c28f949..89712fa 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -61,15 +61,7 @@ jobs: git config --global user.name "GitHub Actions" - name: Un-SNAP - run: | - mvnwPath=$(readlink -f ./mvnw) - modules=("") # root - modules+=($(grep -oP '(?<=)[^<]+' 'pom.xml')) - for i in "${modules[@]}" - do - echo "Processing $i/pom.xml" - (cd "$i" && $mvnwPath -B versions:set -DremoveSnapshot -DgenerateBackupPoms=false) - done + run: ./mvnw -B versions:set -DremoveSnapshot -DprocessAllModules -DgenerateBackupPoms=false - name: Get version id: version @@ -185,15 +177,7 @@ jobs: git pull - name: Inc Version and SNAP - run: | - mvnwPath=$(readlink -f ./mvnw) - modules=("") # root - modules+=($(grep -oP '(?<=)[^<]+' 'pom.xml')) - for i in "${modules[@]}" - do - echo "Processing $i/pom.xml" - (cd "$i" && $mvnwPath -B build-helper:parse-version versions:set -DnewVersion=\${parsedVersion.majorVersion}.\${parsedVersion.minorVersion}.\${parsedVersion.nextIncrementalVersion} -DgenerateBackupPoms=false -DnextSnapshot=true -DupdateMatchingVersions=false) - done + run: ./mvnw -B versions:set -DnextSnapshot -DprocessAllModules -DgenerateBackupPoms=false - name: Git Commit and Push run: | From 48f59e6a5c4582e03d57cc9f523785ba23995cd4 Mon Sep 17 00:00:00 2001 From: XDEV Renovate Bot Date: Thu, 3 Jul 2025 04:20:04 +0000 Subject: [PATCH 4/5] Update dependency org.apache.maven.plugins:maven-gpg-plugin to v3.2.8 --- template-placeholder/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/template-placeholder/pom.xml b/template-placeholder/pom.xml index adb902d..85837b2 100644 --- a/template-placeholder/pom.xml +++ b/template-placeholder/pom.xml @@ -164,7 +164,7 @@ org.apache.maven.plugins maven-gpg-plugin - 3.2.7 + 3.2.8 sign-artifacts From 23eab491b4740bba9fc3f3a329958d6ef84c5389 Mon Sep 17 00:00:00 2001 From: AB Date: Thu, 3 Jul 2025 09:21:28 +0200 Subject: [PATCH 5/5] Implement dual publishing to GitHub packages --- .github/workflows/release.yml | 23 ++++++++++++++++++++--- .github/workflows/test-deploy.yml | 21 +++++++++++++++++++-- template-placeholder/pom.xml | 10 ++++++++-- 3 files changed, 47 insertions(+), 7 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 89712fa..210ef8c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -104,6 +104,9 @@ jobs: runs-on: ubuntu-latest needs: [prepare-release] timeout-minutes: 60 + permissions: + contents: read + packages: write steps: - uses: actions/checkout@v4 @@ -112,20 +115,34 @@ jobs: git config --global user.email "actions@github.com" git config --global user.name "GitHub Actions" git pull + + - name: Set up JDK + uses: actions/setup-java@v4 + with: # running setup-java overwrites the settings.xml + distribution: 'temurin' + java-version: '17' + gpg-passphrase: MAVEN_GPG_PASSPHRASE + gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Only import once + - name: Publish to Central Portal + run: ../mvnw -B deploy -P publish -DskipTests -DaltDeploymentRepository=github::https://maven.pkg.github.com/${{ github.repository }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }} + working-directory: ${{ env.PRIMARY_MAVEN_MODULE }} + - name: Set up JDK uses: actions/setup-java@v4 with: # running setup-java again overwrites the settings.xml - java-version: '17' distribution: 'temurin' + java-version: '17' server-id: sonatype-central-portal server-username: MAVEN_CENTRAL_USERNAME server-password: MAVEN_CENTRAL_TOKEN gpg-passphrase: MAVEN_GPG_PASSPHRASE - gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} - name: Publish to Central Portal - run: ../mvnw -B deploy -P publish-sonatype-central-portal -DskipTests + run: ../mvnw -B deploy -P publish,publish-sonatype-central-portal -DskipTests env: MAVEN_CENTRAL_USERNAME: ${{ secrets.SONATYPE_MAVEN_CENTRAL_PORTAL_USERNAME }} MAVEN_CENTRAL_TOKEN: ${{ secrets.SONATYPE_MAVEN_CENTRAL_PORTAL_TOKEN }} diff --git a/.github/workflows/test-deploy.yml b/.github/workflows/test-deploy.yml index 8a85891..922eda0 100644 --- a/.github/workflows/test-deploy.yml +++ b/.github/workflows/test-deploy.yml @@ -10,8 +10,26 @@ jobs: publish-maven: runs-on: ubuntu-latest timeout-minutes: 60 + permissions: + contents: read + packages: write steps: - uses: actions/checkout@v4 + + - name: Set up JDK + uses: actions/setup-java@v4 + with: # running setup-java overwrites the settings.xml + distribution: 'temurin' + java-version: '17' + gpg-passphrase: MAVEN_GPG_PASSPHRASE + gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} # Only import once + + - name: Publish to GitHub Packages + run: ../mvnw -B deploy -P publish -DskipTests -DaltDeploymentRepository=github::https://maven.pkg.github.com/${{ github.repository }} + working-directory: ${{ env.PRIMARY_MAVEN_MODULE }} + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }} - name: Set up JDK uses: actions/setup-java@v4 @@ -22,10 +40,9 @@ jobs: server-username: MAVEN_CENTRAL_USERNAME server-password: MAVEN_CENTRAL_TOKEN gpg-passphrase: MAVEN_GPG_PASSPHRASE - gpg-private-key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }} - name: Publish to Central Portal - run: ../mvnw -B deploy -P publish-sonatype-central-portal -DskipTests + run: ../mvnw -B deploy -P publish,publish-sonatype-central-portal -DskipTests working-directory: ${{ env.PRIMARY_MAVEN_MODULE }} env: MAVEN_CENTRAL_USERNAME: ${{ secrets.SONATYPE_MAVEN_CENTRAL_PORTAL_USERNAME }} diff --git a/template-placeholder/pom.xml b/template-placeholder/pom.xml index adb902d..d51a7a1 100644 --- a/template-placeholder/pom.xml +++ b/template-placeholder/pom.xml @@ -141,7 +141,7 @@ - publish-sonatype-central-portal + publish @@ -183,7 +183,13 @@ - + + + + + publish-sonatype-central-portal + + org.sonatype.central central-publishing-maven-plugin