From 26153f0f8ab4a1020d001cdc7af2f5078c32851a Mon Sep 17 00:00:00 2001 From: "Eshan Roy (Eshanized)" <148610067+eshanized@users.noreply.github.com> Date: Sun, 16 Jun 2024 01:47:25 +0530 Subject: [PATCH] =?UTF-8?q?=F0=9F=94=A7=20fix(check):=20error:=20Commit=20?= =?UTF-8?q?message=20is=20not=20conventional?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/commit.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/commit.yml b/.github/workflows/commit.yml index 2621fff..2fdd242 100644 --- a/.github/workflows/commit.yml +++ b/.github/workflows/commit.yml @@ -25,7 +25,7 @@ jobs: commit_emojis=("build"="๐Ÿ—๏ธ" "chore"="๐Ÿงน" "ci"="๐Ÿค–" "docs"="๐Ÿ“š" "feat"="๐ŸŽ‰" "fix"="๐Ÿ”ง" "perf"="โšก๏ธ" "refactor"="๐Ÿ’ก" "revert"="๐Ÿšจ" "style"="๐Ÿ’„" "test"="๐Ÿงช") for type in "${conventional_types[@]}"; do - if [[ $LATEST_COMMIT_MESSAGE == *"${commit_emojis[$type]} $type:"* ]] || [[ $LATEST_COMMIT_MESSAGE == *"${commit_emojis[$type]} $type("* ]]; then + if echo "$LATEST_COMMIT_MESSAGE" | grep -qE "^${commit_emojis[$type]} ${type}(:|:)"; then echo "Conventional commit message found: $LATEST_COMMIT_MESSAGE" exit 0 fi