test PRs also with JDK 17 and 21 #186
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: XTF Maven Release | |
on: | |
push: | |
branches: | |
- '**' | |
tags: | |
- '**' | |
jobs: | |
test: | |
name: Deploy to Maven repos | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Set up JDK 8 | |
uses: actions/setup-java@v1 | |
with: | |
java-version: 8 | |
java-package: jdk | |
architecture: x64 | |
- name: Check well-formatted code | |
run: mvn -B formatter:validate impsort:check | |
- name: Maven Package | |
run: mvn install -B -DskipTests=true -Dmaven.javadoc.skip=true -B -V | |
- name: Maven Verify | |
run: mvn -B clean verify | |
- name: maven-settings-xml-action | |
uses: whelk-io/maven-settings-xml-action@v12 | |
with: | |
servers: '[{ "id": "jboss-releases-repository", "username": "${env.JBOSS_REPO_USER}", "password": "${env.JBOSS_REPO_PASSWORD}" },{ "id": "jboss-snapshots-repository", "username": "${env.JBOSS_REPO_USER}", "password": "${env.JBOSS_REPO_PASSWORD}" }]' | |
- name: Import GPG Key | |
uses: crazy-max/ghaction-import-gpg@v1 | |
env: | |
GPG_PRIVATE_KEY: ${{ secrets.GPG_PRIVATE_KEY }} | |
PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} | |
- name: Maven Deploy | |
run: mvn -X deploy -DskipTests -Prelease | |
env: | |
JBOSS_REPO_PASSWORD: ${{ secrets.JBOSS_REPO_PASSWORD }} | |
JBOSS_REPO_USER: ${{ secrets.JBOSS_REPO_USER }} | |