From c0e239b48c57d8a73fb3558443a0e6e4cbae5740 Mon Sep 17 00:00:00 2001 From: dvgaba Date: Mon, 8 Aug 2022 23:11:21 -0400 Subject: [PATCH 1/8] Update maven.yml --- .github/workflows/maven.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 6b91476..6c7db21 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -16,5 +16,23 @@ jobs: uses: actions/setup-java@v1 with: java-version: 11 + - name: Build with Maven run: mvn clean package + + - name: Generate Jacoco Badge + id: jacoco + uses: cicirello/jacoco-badge-generator@v2 + with: + generate-branches-badge: true + + - name: Log coverage percentage + run: | + echo "coverage = ${{ steps.jacoco.outputs.coverage }}" + echo "branches = ${{ steps.jacoco.outputs.branches }}" + + - name: Upload Jacoco coverage report + uses: actions/upload-artifact@v3 + with: + name: jacoco-report + path: target/site/jacoco/ From 3f8b7b3cff180e79da52ed632be7c2a92302a040 Mon Sep 17 00:00:00 2001 From: dvgaba Date: Mon, 8 Aug 2022 23:16:35 -0400 Subject: [PATCH 2/8] Update maven.yml --- .github/workflows/maven.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 6c7db21..6072438 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -25,6 +25,12 @@ jobs: uses: cicirello/jacoco-badge-generator@v2 with: generate-branches-badge: true + jacoco-csv-file: > + easy-rules-core/target/site/jacoco/jacoco.csv + easy-rules-jexl/target/site/jacoco/jacoco.csv + easy-rules-mvel/target/site/jacoco/jacoco.csv + easy-rules-spel/target/site/jacoco/jacoco.csv + easy-rules-support/target/site/jacoco/jacoco.csv - name: Log coverage percentage run: | From e90cad727b59b3b2926bd84aae77543724cfaedc Mon Sep 17 00:00:00 2001 From: dvgaba Date: Mon, 8 Aug 2022 23:21:01 -0400 Subject: [PATCH 3/8] Update maven.yml --- .github/workflows/maven.yml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 6072438..4afaa61 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -37,8 +37,12 @@ jobs: echo "coverage = ${{ steps.jacoco.outputs.coverage }}" echo "branches = ${{ steps.jacoco.outputs.branches }}" - - name: Upload Jacoco coverage report - uses: actions/upload-artifact@v3 - with: - name: jacoco-report - path: target/site/jacoco/ + - name: Commit the badge (if it changed) + run: | + if [[ `git status --porcelain` ]]; then + git config --global user.name 'Dhruv Gaba' + git config --global user.email 'dvgaba@users.noreply.github.com' + git add -A + git commit -m "Autogenerated JaCoCo coverage badge" + git push + fi From 1ac9639ec5ef4cc7ade4773c531535529b059b00 Mon Sep 17 00:00:00 2001 From: dvgaba Date: Mon, 8 Aug 2022 23:23:03 -0400 Subject: [PATCH 4/8] Update maven.yml --- .github/workflows/maven.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 4afaa61..b29d994 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -41,7 +41,7 @@ jobs: run: | if [[ `git status --porcelain` ]]; then git config --global user.name 'Dhruv Gaba' - git config --global user.email 'dvgaba@users.noreply.github.com' + git config --global user.email 'dvgaba@gmail.com' git add -A git commit -m "Autogenerated JaCoCo coverage badge" git push From 76f136a5753d4ecc5ae37db46829f4eaae560b45 Mon Sep 17 00:00:00 2001 From: dvgaba Date: Mon, 8 Aug 2022 23:29:28 -0400 Subject: [PATCH 5/8] Update maven.yml --- .github/workflows/maven.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index b29d994..ba58395 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -40,8 +40,6 @@ jobs: - name: Commit the badge (if it changed) run: | if [[ `git status --porcelain` ]]; then - git config --global user.name 'Dhruv Gaba' - git config --global user.email 'dvgaba@gmail.com' git add -A git commit -m "Autogenerated JaCoCo coverage badge" git push From bf3c005948238c0e8fc967c01d7f281bd3786a65 Mon Sep 17 00:00:00 2001 From: dvgaba Date: Mon, 8 Aug 2022 23:32:17 -0400 Subject: [PATCH 6/8] Update maven.yml --- .github/workflows/maven.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index ba58395..f683115 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -40,6 +40,8 @@ jobs: - name: Commit the badge (if it changed) run: | if [[ `git status --porcelain` ]]; then + git config --global user.name "${{ env.CI_COMMIT_AUTHOR }}" + git config --global user.email "dvgaba@users.noreply.github.com" git add -A git commit -m "Autogenerated JaCoCo coverage badge" git push From dbf8500c95885a06d3d5a123e08893f154347620 Mon Sep 17 00:00:00 2001 From: dvgaba <3621249+dvgaba@users.noreply.github.com> Date: Mon, 8 Aug 2022 23:35:14 -0400 Subject: [PATCH 7/8] Update maven.yml --- .github/workflows/maven.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index f683115..4b9a6ec 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -41,7 +41,7 @@ jobs: run: | if [[ `git status --porcelain` ]]; then git config --global user.name "${{ env.CI_COMMIT_AUTHOR }}" - git config --global user.email "dvgaba@users.noreply.github.com" + git config --global user.email "3621249+dvgaba@users.noreply.github.com" git add -A git commit -m "Autogenerated JaCoCo coverage badge" git push From e6ece04a84585b3ca8297f27930a499a7887d86a Mon Sep 17 00:00:00 2001 From: dvgaba <3621249+dvgaba@users.noreply.github.com> Date: Mon, 8 Aug 2022 23:38:26 -0400 Subject: [PATCH 8/8] Update maven.yml --- .github/workflows/maven.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven.yml b/.github/workflows/maven.yml index 4b9a6ec..ae1fcc7 100644 --- a/.github/workflows/maven.yml +++ b/.github/workflows/maven.yml @@ -40,7 +40,7 @@ jobs: - name: Commit the badge (if it changed) run: | if [[ `git status --porcelain` ]]; then - git config --global user.name "${{ env.CI_COMMIT_AUTHOR }}" + git config --global user.name "dvgaba" git config --global user.email "3621249+dvgaba@users.noreply.github.com" git add -A git commit -m "Autogenerated JaCoCo coverage badge"