details, updated version, fixing actions #76
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: build | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
MAVEN_OPTS: -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up JDK | |
uses: actions/setup-java@v4 | |
with: | |
java-version: 11 | |
distribution: 'temurin' | |
cache: maven | |
server-id: ossrh | |
server-username: SONATYPE_USERNAME | |
server-password: SONATYPE_PASSWORD | |
gpg-private-key: ${{ secrets.GPG_SECRET_KEY }} | |
gpg-passphrase: GPG_SECRET_KEY_PASSPHRASE | |
- name: Build with Maven | |
run: mvn -B -fae | |
- uses: codecov/codecov-action@v4.0.1 | |
- name: Publish Unit Test Results | |
uses: EnricoMi/publish-unit-test-result-action@v2.12.0 | |
if: (success() || failure()) | |
with: | |
junit_files: "**/target/surefire-reports/*.xml" | |
- name: Deploy with Maven | |
run: mvn -B -Pdeploy -DskipTests=true deploy | |
if: ${{ github.event_name == 'push' }} | |
env: | |
SONATYPE_USERNAME: ${{ secrets.OSSRH_USERNAME }} | |
SONATYPE_PASSWORD: ${{ secrets.OSSRH_PASSWORD }} | |
GPG_SECRET_KEY_PASSPHRASE: ${{ secrets.GPG_SECRET_KEY_PASSPHRASE }} |