feat: some changes
This commit is contained in:
parent
92289b23b2
commit
b91691de01
|
|
@ -11,8 +11,6 @@ on:
|
|||
MAVEN_SECRET:
|
||||
required: true
|
||||
|
||||
permissions: read-all
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build
|
||||
|
|
|
|||
|
|
@ -0,0 +1,43 @@
|
|||
on:
|
||||
workflow_call:
|
||||
inputs:
|
||||
name:
|
||||
type: string
|
||||
required: true
|
||||
MAVEN_USER:
|
||||
type: string
|
||||
required: true
|
||||
secrets:
|
||||
MAVEN_SECRET:
|
||||
required: true
|
||||
|
||||
jobs:
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up JDK
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
java-version: '17'
|
||||
distribution: 'temurin'
|
||||
|
||||
- name: Install Maven
|
||||
run: sudo apt update && sudo apt-get install maven -y
|
||||
|
||||
- name: Prepare Maven credentials
|
||||
uses: s4u/maven-settings-action@v2.6.0
|
||||
with:
|
||||
servers: |
|
||||
[{
|
||||
"id": "repo",
|
||||
"username": "${{ vars.MAVEN_NAME }}",
|
||||
"password": "${{ secrets.MAVEN_SECRET }}"
|
||||
}]
|
||||
|
||||
- name: Deploy with Maven
|
||||
run: mvn deploy
|
||||
|
|
@ -11,8 +11,6 @@ on:
|
|||
MAVEN_SECRET:
|
||||
required: true
|
||||
|
||||
permissions: read-all
|
||||
|
||||
jobs:
|
||||
test:
|
||||
name: Test
|
||||
|
|
@ -43,3 +41,11 @@ jobs:
|
|||
|
||||
- name: Run tests with Maven
|
||||
run: mvn test
|
||||
|
||||
- name: Test Report
|
||||
uses: dorny/test-reporter@v1
|
||||
if: success() || failure()
|
||||
with:
|
||||
name: Tests
|
||||
path: "**/target/surefire-reports/TEST-*.xml"
|
||||
reporter: jest-junit
|
||||
|
|
|
|||
Loading…
Reference in New Issue