Skip to content

Commit

Permalink
fixup! chore(ci): lint for bang commits (fixup, squash, drop, edit)
Browse files Browse the repository at this point in the history
  • Loading branch information
Restioson committed Oct 28, 2024
1 parent 05dfeec commit 94f340b
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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!'"

0 comments on commit 94f340b

Please sign in to comment.