trying ci fix #129
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ci | |
on: | |
push: | |
pull_request: | |
branches: [master] | |
workflow_dispatch: | |
jobs: | |
build: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }}-${{ matrix.os }}-${{ matrix.java-version }}-${{ matrix.keyring }} | |
cancel-in-progress: true | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- os: "ubuntu-latest" | |
java-version: 17 | |
distribution: 'adopt' | |
keyring: 'gnome' | |
- os: "ubuntu-latest" | |
java-version: 17 | |
distribution: 'adopt' | |
keyring: 'kde' | |
- os: "macos-latest" | |
java-version: 17 | |
distribution: 'adopt' | |
- os: 'windows-latest' | |
java-version: 17 | |
distribution: 'adopt' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Install packages on linux | |
run: > | |
if [ "$(expr substr $(uname -s) 1 5)" == "Linux" ] && [ "${{matrix.keyring}}" == "gnome" ]; then | |
sudo apt-get -qq install -y --no-install-recommends dbus-x11 gnome-keyring dbus libdbus-glib-1-dev libsecret-tools | |
elif [ "$(expr substr $(uname -s) 1 5)" == "Linux" ] && [ "${{matrix.keyring}}" == "kde" ]; then | |
sudo apt-get -qq install -y --no-install-recommends dbus-x11 kwalletcli | |
fi | |
shell: bash | |
- name: Set up Java | |
uses: actions/setup-java@v3 | |
with: | |
distribution: ${{ matrix.distribution }} | |
java-version: ${{ matrix.java-version }} | |
- name: Maven Install (macos, windows) | |
if: (matrix.os != 'ubuntu-latest') | |
run: mvn --batch-mode --update-snapshots -Dgpg.skip=true install | |
shell: bash | |
- name: Maven Install (linux) | |
if: (matrix.os == 'ubuntu-latest') | |
run: | | |
# kwalletcli needs a "working" display | |
xvfb-run --auto-servernum bash <<EOF | |
# gnome needs setup work as well. | |
source $GITHUB_WORKSPACE/.setupkeystore.sh ${{matrix.keyring}} | |
mvn --batch-mode --update-snapshots -Dgpg.skip=true install | |
EOF | |
shell: bash | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v3 |