You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Eric Carlson <er...@group-technical.com> on 2004/08/04 11:51:11 UTC

commit-email.pl

Try as I might, I find perl incomprehensibe :-(
I have set up the commit-email.pl trigger and it is working great. I
set it up to send emails to a gateway on a web forum, but the size of
these is causing problems when in fact we only need the top part. Can
anyone show me how to set that script so it does exactly what it does
now but just without the diffs in the body please?

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org


Re: commit-email.pl

Posted by Mark Bohlman <mb...@tcicredit.com>.
Eric Carlson wrote:
> Try as I might, I find perl incomprehensibe :-(
> I have set up the commit-email.pl trigger and it is working great. I
> set it up to send emails to a gateway on a web forum, but the size of
> these is causing problems when in fact we only need the top part. Can
> anyone show me how to set that script so it does exactly what it does
> now but just without the diffs in the body please?

Try a couple of things:
On about line 47 (haven't updated sources in a week or two so may be 
different for you), there is a no_diff_deleted flag.  Set the value = 1 
as in the comment.

On line 273 & 274 (or there abouts) is where the diffs are gathered. 
You can comment these out (start the line with a '#') if you don't want 
the overhead of running the svnlook command to gather the diffs

Then finally on line 356 (or so) comment out the line (with a '#') that is:
push(@body, map { /[\r\n]+$/ ? $_ : "$_\n" } @difflines);

This will keep the diffs from appearing in the body of the email.

Note that I have not tried this myself as I do want to see the diffs in 
my emails, so your mileage may vary.

Hope this helps.
-- Mark


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: commit-email.pl

Posted by "C. Michael Pilato" <cm...@collab.net>.
Eric Carlson <er...@group-technical.com> writes:

> Try as I might, I find perl incomprehensibe :-(
> I have set up the commit-email.pl trigger and it is working great. I
> set it up to send emails to a gateway on a web forum, but the size of
> these is causing problems when in fact we only need the top part. Can
> anyone show me how to set that script so it does exactly what it does
> now but just without the diffs in the body please?

If you have the Python bindings built, I would strongly consider
switching to mailer.py (found in tools/hook-scripts/mailer/).  There,
you can simply set the 'generate_diffs' configuration value to 'none',
and *poof* no diffs.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org