send-email: check for repo before invoking hook
commit177409e5897988f03e0c8111c94db6ea0466b138
authorJonathan Tan <jonathantanmy@google.com>
Thu, 1 Jun 2017 23:50:55 +0000 (1 16:50 -0700)
committerJunio C Hamano <gitster@pobox.com>
Fri, 2 Jun 2017 01:58:25 +0000 (2 10:58 +0900)
tree3065e4a03620792a5796e4ea27b1ea34f6d4e699
parent6489660b4bba7456fac0d0a41f5d6295c5900c5f
send-email: check for repo before invoking hook

Unless --no-validate is passed, send-email will invoke
$repo->repo_path() in its search for a validate hook regardless of
whether a Git repo is actually present.  Teach send-email to first check
for repo existence.

Signed-off-by: Jonathan Tan <jonathantanmy@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-send-email.perl
t/t9001-send-email.sh