Subject: Re: [PATCH] Convert emailing part of hooks--update to hooks--post-receive

From: Junio C Hamano <[email-masked]>
Date: Sun, 25 Mar 2007 02:13:04 -0700

Andy Parkins <[email-masked]> writes:

> On Sunday 2007, March 25, Junio C Hamano wrote:
> ...
>> I think you can do something along the following line.
>>
>>  (1) You say "for-each-ref --all" to get the ref information
>>      that is after update.
>
> Would you mind if I delayed that to a separate patch?

Surely.

As we discussed, I would prefer a patch to create this as a new
file in

	contrib/examples/hooks/

directory.  A single-liner 

	# see contrib/example/hooks for examples.

in another new file "templates/hooks--post-receive" would be
also nice.

>> Actually it was not quite "nicely done".  If taggername has an
>> unusual character then dq pair you hard coded there may not
>> quote the string correctly.
>
> Devious.

and funny, isn't it?

>   generate_email $2 $3 $1 | cat
>
> This is to force the deactivation of the pager for all the git commands 
> that generate_email calls.

I think you could probably do the same with:

	PAGER= generate_email "$2" "$3" "$1"