You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Sean McBride <se...@rogue-research.com> on 2006/03/09 21:20:28 UTC

commit-email.pl: supressing diff for certain filetypes?

Hello,

I am using the commit-email.pl script to receive emails about changes to
our repository.  It is great!

The only problem is that it likes to diff .pdf files, resulting in huge
emails of mostly hex garbage.

Can it be told to only diff files with (or without) certain filename
extensions?

Thanks,

-- 
____________________________________________________________
Sean McBride, B. Eng                 sean@rogue-research.com
Rogue Research                        www.rogue-research.com 
Mac Software Developer              Montréal, Québec, Canada



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


Re: commit-email.pl: supressing diff for certain filetypes?

Posted by Ryan Schmidt <su...@ryandesign.com>.
On Mar 9, 2006, at 22:20, Sean McBride wrote:

> I am using the commit-email.pl script to receive emails about  
> changes to
> our repository.  It is great!
>
> The only problem is that it likes to diff .pdf files, resulting in  
> huge
> emails of mostly hex garbage.
>
> Can it be told to only diff files with (or without) certain filename
> extensions?

Subversion will only diff files with text/* MIME types, so you need  
to ensure that your PDFs get into the repository with the application/ 
pdf MIME type. Subversion's auto-props and pre-commit hook features  
can help you get this set properly on all new files:

<http://subversion.tigris.org/faq.html#auto-props>

For files already in your repository, there are scripts which can help:

<http://svn.collab.net/viewvc/svn/tags/1.3.0/contrib/client-side/ 
svn_apply_autoprops.py?view=markup>

<http://matt-good.net/2005/12/23/new-and-improved-svn-apply-autoprops- 
py-now-with-more-svk/>

In fact, in trying to test this problem just now, PDFs do get added  
as application/octet-stream for me, so svnlook (and therefore commit- 
email.pl) does not produce a diff. Perhaps this is a recent change  
(I'm using Subversion 1.3.0) or perhaps there's another reason why  
your PDFs are getting into your repository with a text/* MIME type.  
Either way, you can fix it with the above.



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