From cfda621e5bf0a926f59d82ddaf684d19eeb660c5 Mon Sep 17 00:00:00 2001 From: Sonal Goyal Date: Fri, 11 Oct 2024 16:20:25 +0530 Subject: [PATCH] junit workflow CI/CD --- .github/maven.yml | 19 ---------------- .github/workflows/junits.yml | 44 ++++++++++-------------------------- 2 files changed, 12 insertions(+), 51 deletions(-) delete mode 100644 .github/maven.yml diff --git a/.github/maven.yml b/.github/maven.yml deleted file mode 100644 index 4874cc4b1..000000000 --- a/.github/maven.yml +++ /dev/null @@ -1,19 +0,0 @@ -name: Java CI - -on: [push] - -jobs: - build: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - name: Set up JDK 8 - uses: actions/setup-java@v2 - with: - java-version: '8' - distribution: 'adopt' - - name: mvn init - run: mvn initialize - - name: Build with Maven - run: mvn clean compile package diff --git a/.github/workflows/junits.yml b/.github/workflows/junits.yml index 92daae633..4874cc4b1 100644 --- a/.github/workflows/junits.yml +++ b/.github/workflows/junits.yml @@ -1,39 +1,19 @@ -# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time -# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-maven +name: Java CI -# This workflow uses actions that are not certified by GitHub. -# They are provided by a third-party and are governed by -# separate terms of service, privacy policy, and support -# documentation. - -name: buildAndRunTests - -on: - push: - branches: [ "*" ] - pull_request: - branches: [ "*" ] +on: [push] jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - name: Set up JDK 11 - uses: actions/setup-java@v3 - with: - java-version: '11' - distribution: 'temurin' - cache: maven - - name: mvn init - run: mvn initialize - - name: Clean the build - run: mvn clean - - name: Install libs - run: mvn validate - - name: Build with Maven - run: mvn -U -B package --file pom.xml - - + - uses: actions/checkout@v2 + - name: Set up JDK 8 + uses: actions/setup-java@v2 + with: + java-version: '8' + distribution: 'adopt' + - name: mvn init + run: mvn initialize + - name: Build with Maven + run: mvn clean compile package