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

Re: Partial read-only repository?

From: Tim Moloney <moloney_at_mrsl.com>
Date: 2002-04-11 23:09:33 CEST

cmpilato@collab.net wrote:
> Tim Moloney <moloney@mrsl.com> writes:
>
>
>>Following the example of http://svn.collab.net/repos/svn/, I've
>>created a repository that has the following structure
>>
>> /svn/project/trunk
>> /svn/project/tags
>> /svn/project/branches
>>
>>I know that the only difference between tags and branches is that
>>tags won't (shouldn't) have anything commited back to them.
>>
>>Unfortunately, people make mistakes, is there a way to make the
>>tags directory read-only to prevent accidental commits that would
>>corrupt the tagged revision?
>
>
> You could write a pre-commit hook that uses svnlook to determine which
> paths were being modified. If the tags directory is being modified,
> and if those mods were anything more than just the creation of a new
> tag, the hook returns and error, and the commit doesn't happen. You
> could even have the script send email to the would-be committer
> saying, "I know what you tried to do, buck-o!"

Thanks for the info.

I don't have it running perfectly yet but I do have a few
comments for the archives.

.../svn/subversion/libsvn_repos/hooks.txt is a good place to
start. However, it needs to be updated to show the scripts in
the <repos>/hooks directory, not the <repos>/conf directory.

It would also be nice to mention that the script has to be
executable by the owner of the httpd process. This tripped me
up for a little bit.

-- 
Tim Moloney
ManTech Real-time Systems Laboratory
2015 Cattlemen Road                             \     /
Sarasota, FL  34232                     .________\(O)/________.
(941) 377-6775 x208                        '  '  O(.)O  '  '
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Apr 11 23:09:32 2002

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

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