summaryrefslogtreecommitdiff
path: root/git-send-email.perl
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2021-05-27 03:36:57 (GMT)
committerJunio C Hamano <gitster@pobox.com>2021-05-27 03:36:57 (GMT)
commitf4d715b0acaf008d0f09c42378cac90acaadea8e (patch)
treee87a3bdac9d479f29c36c5713697631dd530167d /git-send-email.perl
parent1accb34ce0055b9ab43cdf1a8ef6e22e7ae34ffc (diff)
parent7cbc0455cc07702c5eeff1062c7e2a820758714f (diff)
downloadgit-f4d715b0acaf008d0f09c42378cac90acaadea8e.zip
git-f4d715b0acaf008d0f09c42378cac90acaadea8e.tar.gz
git-f4d715b0acaf008d0f09c42378cac90acaadea8e.tar.bz2
Merge branch 'ab/send-email-inline-hooks-path'
Code simplification. * ab/send-email-inline-hooks-path: send-email: move "hooks_path" invocation to git-send-email.perl send-email: don't needlessly abs_path() the core.hooksPath
Diffstat (limited to 'git-send-email.perl')
-rwxr-xr-xgit-send-email.perl3
1 files changed, 2 insertions, 1 deletions
diff --git a/git-send-email.perl b/git-send-email.perl
index 170f42f..25be2eb 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -1959,7 +1959,8 @@ sub validate_patch {
my ($fn, $xfer_encoding) = @_;
if ($repo) {
- my $validate_hook = catfile($repo->hooks_path(),
+ my $hooks_path = $repo->command_oneline('rev-parse', '--git-path', 'hooks');
+ my $validate_hook = catfile($hooks_path,
'sendemail-validate');
my $hook_error;
if (-x $validate_hook) {