From: Junio C Hamano <gitster@pobox.com>
To: Cheng Leong <leongc@alumni.rice.edu>
Cc: git@vger.kernel.org, kpfleming@digium.com
Subject: Re: [PATCH/RFC] Restore line limit option in post-receive-email
Date: Thu, 10 Nov 2011 22:56:07 -0800 [thread overview]
Message-ID: <7v4nybrvug.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <1320993311-27112-1-git-send-email-leongc@alumni.rice.edu> (Cheng Leong's message of "Fri, 11 Nov 2011 00:35:11 -0600")
Cheng Leong <leongc@alumni.rice.edu> writes:
> The hooks.emailmaxlines config currently has no effect. Stop
> prep_for_email from clobbering the already-initialized maxlines
> variable in the contrib/hooks/post-receive-email example.
>
> Signed-off-by: Cheng Leong <leongc@alumni.rice.edu>
> ---
> contrib/hooks/post-receive-email | 1 -
> 1 files changed, 0 insertions(+), 1 deletions(-)
>
> diff --git a/contrib/hooks/post-receive-email b/contrib/hooks/post-receive-email
> index ba077c1..ac2e0ed 100755
> --- a/contrib/hooks/post-receive-email
> +++ b/contrib/hooks/post-receive-email
> @@ -85,7 +85,6 @@ prep_for_email()
> oldrev=$(git rev-parse $1)
> newrev=$(git rev-parse $2)
> refname="$3"
> - maxlines=$4
>
> # --- Interpret
> # 0000->1234 (create)
Umm, there is another place where $maxlines is used without
merit. Shouldn't we do something like below as well?
contrib/hooks/post-receive-email | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/contrib/hooks/post-receive-email b/contrib/hooks/post-receive-email
index ba077c1..e27ca3c 100755
--- a/contrib/hooks/post-receive-email
+++ b/contrib/hooks/post-receive-email
@@ -743,6 +743,6 @@ else
while read oldrev newrev refname
do
prep_for_email $oldrev $newrev $refname || continue
- generate_email $maxlines | send_mail
+ generate_email | send_mail
done
fi
next prev parent reply other threads:[~2011-11-11 6:56 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-11 6:35 [PATCH/RFC] Restore line limit option in post-receive-email Cheng Leong
2011-11-11 6:56 ` Junio C Hamano [this message]
2011-11-11 7:08 ` Cheng Leong
2012-01-12 21:01 ` Cheng Leong
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7v4nybrvug.fsf@alter.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=kpfleming@digium.com \
--cc=leongc@alumni.rice.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).