Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify github-actions build. #628

Merged
merged 1 commit into from
Oct 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 0 additions & 14 deletions .github/mvn-toolchains.xml

This file was deleted.

33 changes: 9 additions & 24 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,36 +14,28 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup GPG
- name: Set up GPG
if: env.GPG_SECRET_KEYS != null && env.GPG_OWNERTRUST != null
run: |
cat <(echo -e "${{ env.GPG_SECRET_KEYS }}") | base64 --decode | gpg --batch --import
cat <(echo -e "${{ env.GPG_OWNERTRUST }}") | base64 --decode | gpg --batch --import-ownertrust
env:
GPG_SECRET_KEYS: ${{ secrets.GPG_SECRET_KEYS }}
GPG_OWNERTRUST: ${{ secrets.GPG_OWNERTRUST }}
- name: Set up JDK 17
id: setup-java-17
uses: actions/setup-java@v3
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: 17
java-package: jdk
- name: Setup maven cache
uses: actions/cache@v3
with:
path: ~/.m2/repository
key: ${{ runner.os }}-m2-repo-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2-repo-
cache: maven
- name: Perform build
run: .github/scripts/build.sh
shell: bash
env:
JAVA_17_HOME: ${{ steps.setup-java-17.outputs.path }}
MAVEN_CLI_OPTS: --settings .github/mvn-settings.xml --global-toolchains .github/mvn-toolchains.xml
MAVEN_CLI_OPTS: --settings .github/mvn-settings.xml
GPG_EXECUTABLE: /usr/bin/gpg
GPG_KEYNAME: ${{ secrets.GPG_KEYNAME }}
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
Expand All @@ -64,7 +56,7 @@ jobs:
steps:
- name: Check out code
if: env.GH_TOKEN != null
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ env.GH_TOKEN }}
Expand All @@ -75,18 +67,11 @@ jobs:
git config user.email "ci-user@talsma-ict.nl"
- name: Set up JDK
if: env.GH_TOKEN != null
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
distribution: 'zulu'
java-version: 17
java-package: jdk
- name: Set up maven cache
if: env.GH_TOKEN != null
uses: actions/cache@v3
with:
path: ~/.m2/repository
key: ${{ runner.os }}-m2-repo-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2-repo-
cache: 'maven'
- name: Perform optional release
if: env.GH_TOKEN != null
run: .github/scripts/release.sh
Expand Down