diff --git a/.github/workflows/push-and-pull_request.yml b/.github/workflows/push-and-pull_request.yml
index f9790d098..de5deea4c 100644
--- a/.github/workflows/push-and-pull_request.yml
+++ b/.github/workflows/push-and-pull_request.yml
@@ -1,7 +1,9 @@
name: Build on Push and Pull Request
on:
- - push
- - pull_request
+ push:
+ branches:
+ - master
+ pull_request:
jobs:
build:
@@ -9,25 +11,26 @@ jobs:
strategy:
fail-fast: false
matrix:
- # Supported versions as of https://en.wikipedia.org/wiki/Java_version_history
+ # Supported LTS versions as of https://en.wikipedia.org/wiki/Java_version_history
java-version:
- 8
- 11
- - 16
+ - 17
+ - 21
name: Build with JDK ${{ matrix.java-version }}
steps:
- name: Cache Dependencies
- uses: actions/cache@v3
+ uses: actions/cache@v4
with:
key: maven-dependencies
path: ~/.m2/repository
- name: Check out
- uses: actions/checkout@v3
+ uses: actions/checkout@v4
- name: Set up JDK ${{ matrix.java-version }}
- uses: actions/setup-java@v3
+ uses: actions/setup-java@v4
with:
- distribution: adopt
+ distribution: temurin
java-version: ${{ matrix.java-version }}
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }}
gpg-passphrase: GPG_PASSPHRASE
@@ -38,6 +41,7 @@ jobs:
set +o errexit +o pipefail
- id: version
name: Evaluate Version
+ shell: bash {0}
run: |
project_version=`mvn help:evaluate --quiet --define expression=project.version --define forceStdout`
echo "Version: ${project_version}"
@@ -95,7 +99,7 @@ jobs:
fi
- name: Deploy Site
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' && matrix.java-version == 8 && steps.version.outputs.is-snapshot == 'true' }}
- uses: peaceiris/actions-gh-pages@v3.8.0
+ uses: peaceiris/actions-gh-pages@v4.0.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./target/site
diff --git a/pom.xml b/pom.xml
index 2fdde5e4b..64c3d158a 100644
--- a/pom.xml
+++ b/pom.xml
@@ -118,9 +118,9 @@
- com.googlecode.jmockit
+ org.jmockit
jmockit
- 1.7
+ 1.29
test