* [PATCH] fix contrib/hooks/post-receive-email hooks.recipients error message
@ 2007-10-11 21:49 Jeff Muizelaar
0 siblings, 0 replies; only message in thread
From: Jeff Muizelaar @ 2007-10-11 21:49 UTC (permalink / raw)
To: git; +Cc: Andy Parkins
Have the error message for missing recipients actually report the
missing config variable and not a fictional one.
diff --git a/contrib/hooks/post-receive-email b/contrib/hooks/post-receive-email
index cbbd02f..b188aa3 100644
--- a/contrib/hooks/post-receive-email
+++ b/contrib/hooks/post-receive-email
@@ -138,7 +138,15 @@ generate_email()
# Check if we've got anyone to send to
if [ -z "$recipients" ]; then
- echo >&2 "*** hooks.recipients is not set so no email will be sent"
+ case "$refname_type" in
+ "annotated tag")
+ config_name="hooks.announcelist"
+ ;;
+ *)
+ config_name="hooks.mailinglist"
+ ;;
+ esac
+ echo >&2 "*** $config_name is not set so no email will be sent"
echo >&2 "*** for $refname update $oldrev->$newrev"
exit 0
fi
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2007-10-11 22:23 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-10-11 21:49 [PATCH] fix contrib/hooks/post-receive-email hooks.recipients error message Jeff Muizelaar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).