From ba1574109771dd05791749236d4d48842955b919 Mon Sep 17 00:00:00 2001 From: Chandru <125248898+chandru-iamneo@users.noreply.github.com> Date: Thu, 22 Feb 2024 16:28:50 +0530 Subject: [PATCH] Update build.yml if condition --- .github/workflows/build.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 00939ee..34f99e0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -22,6 +22,16 @@ jobs: java-version: 17 - name: Move Pom.xml to Root run: mv .github/workflows/pom.xml ./pom.xml + + - name: Check Commit Message + run: | + if [[ "$(git log --format=%B -n 1)" == *"Submit-project-save-commit"* ]]; then + echo "Commit message contains 'Submit-project-save-commit', proceeding with the workflow." + else + echo "Commit message does not contain 'Submit-project-save-commit', skipping the workflow." + exit 78 # Exiting with a non-zero code to indicate skipping + fi + - name: Build and analyze env: GITHUB_TOKEN: badabeeddcc309774475bedbafbeeacbbathree