From 94f340b6b6d6e7227f6f527adf0d9c69b6fac63e Mon Sep 17 00:00:00 2001 From: Restioson Date: Mon, 28 Oct 2024 14:16:13 +0200 Subject: [PATCH] fixup! chore(ci): lint for bang commits (fixup, squash, drop, edit) --- .github/workflows/testing.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index 11cf731..8add0f2 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -135,6 +135,4 @@ jobs: # - We use a -z here, which makes \0 be the line separator, because if feeding multiline text into grep, it will # exit with a status of 0 regardless of whether there is a match ( - name: Disallow bang commits - run: | - git log --pretty=format:%s origin/main..HEAD | grep "fixup!|squash!|drop!|edit!" - if [ $? -eq 0 ]; then echo "Found bang commit (or error) - rebase required before merge"; exit 1; fi + run: bash -c "! git log --pretty=format:%s origin/main..HEAD | grep 'fixup!|squash!|drop!|edit!'" \ No newline at end of file