Skip to content

Commit

Permalink
test: Add guard when no commit needs testing
Browse files Browse the repository at this point in the history
Without this patch, github actions fail.

It's a temporary workaround until [1] is done.

[1]: purpleidea#643
  • Loading branch information
evrardjp committed Mar 3, 2021
1 parent 35a8062 commit 1873e02
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions test/test-commit-message.sh
Original file line number Diff line number Diff line change
Expand Up @@ -134,12 +134,12 @@ then
head=""
fi
commits=$(git log --no-merges --format=%H origin/${ref}..${head})
[[ -n "$commits" ]]

for commit in $commits
do
test_commit_message $commit
test_commit_message_common_bugs $commit
done
if [[ -n "$commits" ]]; then
for commit in $commits
do
test_commit_message $commit
test_commit_message_common_bugs $commit
done
fi
fi
echo 'PASS'

0 comments on commit 1873e02

Please sign in to comment.