From 97b403ebe726a4f2e70c8399a30cc90bbf4ddca6 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Halimi Date: Wed, 2 Nov 2016 16:41:43 -0700 Subject: [PATCH] Check clang-format during pre-commit Users who do not have clang-format installed were not able to push commits. This patch gives better feedback to the developer by explicitely telling the user to install the package. --- hooks/pre-commit | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/hooks/pre-commit b/hooks/pre-commit index 04fdaf8ec..541f5a3bc 100755 --- a/hooks/pre-commit +++ b/hooks/pre-commit @@ -25,6 +25,13 @@ END exit 1 fi +if ! hash "clang-format" 2> /dev/null; then + cat<