Skip to content

Commit e186cee

Browse files
Fail hard when the commit checker finds no Git repo
When someone invokes the commit checker but there is no repository to check, the script should fail hard. Currently, a warning is emitted but the script does not fail, which leads to the warning being ignored. Signed-off-by: Steve Kuznetsov <[email protected]>
1 parent 95243fd commit e186cee

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

hack/verify-upstream-commits.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
source "$(dirname "${BASH_SOURCE}")/lib/init.sh"
33

44
if ! git status &> /dev/null; then
5-
echo "SKIPPED: Not a Git repository"
6-
exit 0
5+
echo "FAILURE: Not a Git repository"
6+
exit 1
77
fi
88

99
os::util::ensure::built_binary_exists 'commitchecker'

0 commit comments

Comments
 (0)