[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svn:ignore pattern question

From: Ryan Schmidt <subversion-2009a_at_ryandesign.com>
Date: Fri, 27 Feb 2009 17:41:51 -0600

On Feb 27, 2009, at 13:46, mimi huhu wrote:

> Might I ask what's the best way to enforce to commit certain file
> extensions?
> For example, I would like to user to commit those extensions
> (.sh, .pl, .sql, ...) only.
> I checked the link, but I did not see the syntax I might needed.

For that, you need to write a pre-commit hook. In it, you will
examine the incoming transaction using "svnlook changed" and compare
each changed file (which includes added files) with your list of
allowed extensions, and if any file isn't allowed, you print a
message explaining that and exit with a non-zero exit code, which
terminates the commit.


To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-02-28 00:42:53 CET

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.