parent
38b9e4cd49
commit
e1e6ee5ebe
@ -0,0 +1,34 @@
|
|||||||
|
name: Codecov with JDK 17
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- 2024
|
||||||
|
- 2023
|
||||||
|
- 2022
|
||||||
|
pull_request:
|
||||||
|
branches:
|
||||||
|
- 2024
|
||||||
|
- 2023
|
||||||
|
- 2022
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
codecov:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout codes
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
- name: Set up JDK 17
|
||||||
|
uses: actions/setup-java@v4
|
||||||
|
with:
|
||||||
|
distribution: 'temurin'
|
||||||
|
java-version: 17
|
||||||
|
- name: Test with Maven
|
||||||
|
run: mvn clean test -B -U -Psonatype
|
||||||
|
- name: Upload coverage to Codecov
|
||||||
|
uses: codecov/codecov-action@v4
|
||||||
|
env:
|
||||||
|
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
||||||
|
with:
|
||||||
|
files: ${{ github.workspace }}/target/site/jacoco/jacoco.xml
|
@ -1,27 +1,24 @@
|
|||||||
# This workflow will build a Java project with Maven
|
name: Junit Test with JDK from 8 to 21
|
||||||
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-maven
|
|
||||||
|
|
||||||
name: Test with Junit
|
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- hoxton
|
|
||||||
- 2021
|
- 2021
|
||||||
- 2020
|
- 2020
|
||||||
|
- hoxton
|
||||||
- greenwich
|
- greenwich
|
||||||
pull_request:
|
pull_request:
|
||||||
branches:
|
branches:
|
||||||
- hoxton
|
|
||||||
- 2021
|
- 2021
|
||||||
- 2020
|
- 2020
|
||||||
|
- hoxton
|
||||||
- greenwich
|
- greenwich
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
junit:
|
junit:
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
java: [ 8, 11, 17 ]
|
java: [ 8, 11, 17, 21 ]
|
||||||
os: [ 'windows-latest', 'ubuntu-latest' ]
|
os: [ 'windows-latest', 'ubuntu-latest' ]
|
||||||
|
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
@ -1,14 +1,11 @@
|
|||||||
name: Snapshot
|
name: Snapshot with JDK 17
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
|
- 2024
|
||||||
- 2023
|
- 2023
|
||||||
- 2022
|
- 2022
|
||||||
- 2021
|
|
||||||
- 2020
|
|
||||||
- hoxton
|
|
||||||
- greenwich
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
check-snapshot:
|
check-snapshot:
|
@ -0,0 +1,48 @@
|
|||||||
|
name: Snapshot with JDK 8
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- 2021
|
||||||
|
- 2020
|
||||||
|
- hoxton
|
||||||
|
- greenwich
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
check-snapshot:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
outputs:
|
||||||
|
IS_SNAPSHOT: ${{ steps.set_output_1.outputs.IS_SNAPSHOT }}
|
||||||
|
steps:
|
||||||
|
- name: Checkout codes
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
- name: Check deploy type
|
||||||
|
id: set_output_1
|
||||||
|
run: |
|
||||||
|
line="$(grep SNAPSHOT pom.xml || true)"
|
||||||
|
echo $line
|
||||||
|
if [ -n "$line" ]; then
|
||||||
|
echo "IS_SNAPSHOT=true" >> $GITHUB_OUTPUT
|
||||||
|
else
|
||||||
|
echo "IS_SNAPSHOT=false" >> $GITHUB_OUTPUT
|
||||||
|
fi
|
||||||
|
snapshot:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
needs: check-snapshot
|
||||||
|
if: ${{ needs.check-snapshot.outputs.IS_SNAPSHOT == 'true' }}
|
||||||
|
steps:
|
||||||
|
- name: Checkout codes
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
- name: Set up JDK 8
|
||||||
|
uses: actions/setup-java@v4
|
||||||
|
with:
|
||||||
|
java-version: '8'
|
||||||
|
distribution: 'temurin'
|
||||||
|
server-id: nexus-snapshots
|
||||||
|
server-username: MAVEN_USERNAME
|
||||||
|
server-password: MAVEN_PASSWORD
|
||||||
|
- name: Publish package
|
||||||
|
run: mvn clean deploy -B -U -Psonatype
|
||||||
|
env:
|
||||||
|
MAVEN_USERNAME: ${{ secrets.OSSRH_USERNAME }}
|
||||||
|
MAVEN_PASSWORD: ${{ secrets.OSSRH_TOKEN }}
|
Loading…
Reference in new issue