From edb62751ba2c6cd41fa6701d116c63b8f363258c Mon Sep 17 00:00:00 2001 From: Christian Koop Date: Sun, 7 May 2023 14:58:39 +0200 Subject: [PATCH] GitHub Actions: Set increment_version to patch outside of tags When we release v.2.20.1 and add a commit, v2.20.1-SNAPSHOT is published, which is not the correct version. patch-level isn't right either always, but I think that's a good compromise for now. --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b7726e54..0b18c3d9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -44,6 +44,7 @@ jobs: with: append_snapshot: ${{ github.ref_type == 'tag' && 'false' || 'true' }} version: ${{ github.ref_type == 'tag' && github.ref_name || '' }} + increment_version: ${{ github.ref_type == 'tag' && '' || 'patch' }} - name: Build with Maven run: mvn -B -Duser.name="GitHub Actions on $GITHUB_REPOSITORY (id=$GITHUB_RUN_ID)" -DskipTests clean package