From 85bfec54244737a5c1a5728392fb4195b77d664f Mon Sep 17 00:00:00 2001 From: oliverbye Date: Fri, 8 Mar 2024 07:38:59 +0000 Subject: [PATCH 1/3] 2.13.0 --- jmock-example/pom.xml | 2 +- jmock-imposters-testdata/pom.xml | 2 +- jmock-imposters-tests/pom.xml | 2 +- jmock-imposters/pom.xml | 2 +- jmock-junit3/pom.xml | 2 +- jmock-junit4/pom.xml | 2 +- jmock-junit5/pom.xml | 2 +- jmock-legacy/pom.xml | 2 +- jmock/pom.xml | 2 +- pom.xml | 2 +- testjar/pom.xml | 2 +- 11 files changed, 11 insertions(+), 11 deletions(-) diff --git a/jmock-example/pom.xml b/jmock-example/pom.xml index 6e431ef32..0ce1b5485 100644 --- a/jmock-example/pom.xml +++ b/jmock-example/pom.xml @@ -12,7 +12,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 ../pom.xml diff --git a/jmock-imposters-testdata/pom.xml b/jmock-imposters-testdata/pom.xml index 46ee99cbf..502a0885f 100644 --- a/jmock-imposters-testdata/pom.xml +++ b/jmock-imposters-testdata/pom.xml @@ -6,7 +6,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 jmock-imposters-testdata diff --git a/jmock-imposters-tests/pom.xml b/jmock-imposters-tests/pom.xml index 9113310db..f63dfec2e 100644 --- a/jmock-imposters-tests/pom.xml +++ b/jmock-imposters-tests/pom.xml @@ -6,7 +6,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 jmock-imposters-tests diff --git a/jmock-imposters/pom.xml b/jmock-imposters/pom.xml index 153724448..e150d61e1 100644 --- a/jmock-imposters/pom.xml +++ b/jmock-imposters/pom.xml @@ -6,7 +6,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 jmock-imposters Class mocks are more numerous than interface mocks, so drop the legacy name diff --git a/jmock-junit3/pom.xml b/jmock-junit3/pom.xml index b30abe9bd..b7d0daad3 100644 --- a/jmock-junit3/pom.xml +++ b/jmock-junit3/pom.xml @@ -7,7 +7,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 jmock-junit3 diff --git a/jmock-junit4/pom.xml b/jmock-junit4/pom.xml index aac41b1a4..b49e66160 100644 --- a/jmock-junit4/pom.xml +++ b/jmock-junit4/pom.xml @@ -10,7 +10,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 diff --git a/jmock-junit5/pom.xml b/jmock-junit5/pom.xml index c248cc51c..0e2f1f61a 100644 --- a/jmock-junit5/pom.xml +++ b/jmock-junit5/pom.xml @@ -9,7 +9,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 diff --git a/jmock-legacy/pom.xml b/jmock-legacy/pom.xml index 30efb47b6..23915abab 100644 --- a/jmock-legacy/pom.xml +++ b/jmock-legacy/pom.xml @@ -10,7 +10,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 diff --git a/jmock/pom.xml b/jmock/pom.xml index 80bf8261c..1a28f7194 100644 --- a/jmock/pom.xml +++ b/jmock/pom.xml @@ -10,7 +10,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 ../pom.xml diff --git a/pom.xml b/pom.xml index 858df28aa..e91659d5d 100644 --- a/pom.xml +++ b/pom.xml @@ -7,7 +7,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 pom jMock 2 Parent diff --git a/testjar/pom.xml b/testjar/pom.xml index 97557cd47..884800c4e 100644 --- a/testjar/pom.xml +++ b/testjar/pom.xml @@ -11,7 +11,7 @@ org.jmock jmock-parent - 2.13.0-SNAPSHOT + 2.13.0 ../pom.xml From 22935932ea1b7a29c48682dc3e969364ea634172 Mon Sep 17 00:00:00 2001 From: oliverbye Date: Fri, 8 Mar 2024 07:43:07 +0000 Subject: [PATCH 2/3] 2.13.1-SNAPSHOT --- README.DEVELOPMENT | 5 +++-- jmock-example/pom.xml | 2 +- jmock-imposters-testdata/pom.xml | 2 +- jmock-imposters-tests/pom.xml | 2 +- jmock-imposters/pom.xml | 2 +- jmock-junit3/pom.xml | 2 +- jmock-junit4/pom.xml | 2 +- jmock-junit5/pom.xml | 2 +- jmock-legacy/pom.xml | 2 +- jmock/pom.xml | 2 +- pom.xml | 2 +- testjar/pom.xml | 2 +- 12 files changed, 14 insertions(+), 13 deletions(-) diff --git a/README.DEVELOPMENT b/README.DEVELOPMENT index 12bd72b0c..f00b7f61b 100644 --- a/README.DEVELOPMENT +++ b/README.DEVELOPMENT @@ -39,7 +39,7 @@ result of the wrong type. Release ======= -mvn versions:set -DoldVersion=* -DnewVersion=2.10.0 -DgroupId=org.jmock -DgenerateBackupPoms=false +mvn versions:set -DoldVersion=\* -DnewVersion=2.10.0 -DgroupId=org.jmock -DgenerateBackupPoms=false eval $(gpg-agent --daemon --no-grab --write-env-file $HOME/.gpg-agent-info) export GPG_AGENT_INFO @@ -48,5 +48,6 @@ export SONATYPE_USERNAME=UUU export SONATYPE_PASSWORD=PPPP mvn clean deploy -P release --settings settings.xml -Dgpg.keyname=XXXXXXXX -mvn versions:set -DoldVersion=* -DnewVersion=2.11.0-SNAPSHOT -DgroupId=org.jmock -DgenerateBackupPoms=false +mvn versions:set -DoldVersion=\* -DnextSnapshot=true -DgroupId=org.jmock -DgenerateBackupPoms=false + diff --git a/jmock-example/pom.xml b/jmock-example/pom.xml index 0ce1b5485..2196162f7 100644 --- a/jmock-example/pom.xml +++ b/jmock-example/pom.xml @@ -12,7 +12,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT ../pom.xml diff --git a/jmock-imposters-testdata/pom.xml b/jmock-imposters-testdata/pom.xml index 502a0885f..fef697ae2 100644 --- a/jmock-imposters-testdata/pom.xml +++ b/jmock-imposters-testdata/pom.xml @@ -6,7 +6,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT jmock-imposters-testdata diff --git a/jmock-imposters-tests/pom.xml b/jmock-imposters-tests/pom.xml index f63dfec2e..eaa557444 100644 --- a/jmock-imposters-tests/pom.xml +++ b/jmock-imposters-tests/pom.xml @@ -6,7 +6,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT jmock-imposters-tests diff --git a/jmock-imposters/pom.xml b/jmock-imposters/pom.xml index e150d61e1..e495a39b5 100644 --- a/jmock-imposters/pom.xml +++ b/jmock-imposters/pom.xml @@ -6,7 +6,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT jmock-imposters Class mocks are more numerous than interface mocks, so drop the legacy name diff --git a/jmock-junit3/pom.xml b/jmock-junit3/pom.xml index b7d0daad3..2b42cc5f1 100644 --- a/jmock-junit3/pom.xml +++ b/jmock-junit3/pom.xml @@ -7,7 +7,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT jmock-junit3 diff --git a/jmock-junit4/pom.xml b/jmock-junit4/pom.xml index b49e66160..0af8ea998 100644 --- a/jmock-junit4/pom.xml +++ b/jmock-junit4/pom.xml @@ -10,7 +10,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT diff --git a/jmock-junit5/pom.xml b/jmock-junit5/pom.xml index 0e2f1f61a..b54ea2cc7 100644 --- a/jmock-junit5/pom.xml +++ b/jmock-junit5/pom.xml @@ -9,7 +9,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT diff --git a/jmock-legacy/pom.xml b/jmock-legacy/pom.xml index 23915abab..6f123004b 100644 --- a/jmock-legacy/pom.xml +++ b/jmock-legacy/pom.xml @@ -10,7 +10,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT diff --git a/jmock/pom.xml b/jmock/pom.xml index 1a28f7194..108080b9e 100644 --- a/jmock/pom.xml +++ b/jmock/pom.xml @@ -10,7 +10,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT ../pom.xml diff --git a/pom.xml b/pom.xml index e91659d5d..bc3bb08da 100644 --- a/pom.xml +++ b/pom.xml @@ -7,7 +7,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT pom jMock 2 Parent diff --git a/testjar/pom.xml b/testjar/pom.xml index 884800c4e..589957549 100644 --- a/testjar/pom.xml +++ b/testjar/pom.xml @@ -11,7 +11,7 @@ org.jmock jmock-parent - 2.13.0 + 2.13.1-SNAPSHOT ../pom.xml From 1d381d3dcfbd43ffd3669cb34a8029088029a884 Mon Sep 17 00:00:00 2001 From: oliverbye Date: Sun, 10 Mar 2024 14:46:29 +0000 Subject: [PATCH 3/3] Towards github release action --- .github/workflows/release.yml | 35 +++++++++++++++++++ .../workflows/{deploy.yml => snapshot.yml} | 8 ++--- 2 files changed, 37 insertions(+), 6 deletions(-) create mode 100644 .github/workflows/release.yml rename .github/workflows/{deploy.yml => snapshot.yml} (78%) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 000000000..92816e7f3 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,35 @@ +name: Maven deploy release +on: + pull_request: + types: + - opened + branches: + - 'master' # only trigger from master +jobs: + run_if: + if: startsWith(github.head_ref, 'releases/') # targeting releases + publish: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - name: Set up Maven Central Repository + uses: actions/setup-java@v3 + with: + java-version: '8' + distribution: 'temurin' + cache: maven + + - name: Split branch into release version + env: + BRANCH: ${{ github.ref_name }} + id: split + run: echo "::set-output name=fragment::${BRANCH##*/}" + + - name: Maven set release version + run: | + mvn versions:set -DoldVersion=\* -DnewVersion=${{ steps.split.outputs.fragment }} -DgroupId=org.jmock -DgenerateBackupPoms=false + git commit --no-edit + git tag -a -m "Release version ${{ steps.split.outputs.fragment }}" ${{ steps.split.outputs.fragment }} + git push origin HEAD --tags + diff --git a/.github/workflows/deploy.yml b/.github/workflows/snapshot.yml similarity index 78% rename from .github/workflows/deploy.yml rename to .github/workflows/snapshot.yml index 3af4c2954..49653c4be 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/snapshot.yml @@ -1,11 +1,7 @@ -name: Maven deploy to Maven Central +name: Maven deploy snapshot on: push: - # Pattern matched against refs/tags - tags: - - '*' # Push events to every tag not containing / - release: - types: [created] + branches: [ master ] jobs: publish: runs-on: ubuntu-latest