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

Re: Controlling update and/or commit access to a repository URL

From: Nathan Kidd <nathan_at_hummingbird.com>
Date: 2004-09-04 07:40:14 CEST

Lee Merrill wrote:

> Well, I fished a bit, and svnserve can do per-user permissions:
>
> http://svnbook.red-bean.com/svnbook/ch06s03.html#svn-ch-6-sect-3.2.1
>
> But not per-directory permissions. But still a hook script could
> restrict commits on a per-directory basis, and the svnserve permissions
> could do the per-user read access for you. So I think it can be done
> (though I'm new to all this, and may have missed a beat somewhere).

In fact, the svn tarball already contains two different hook scripts to
do exactly this! (take your pick of perl or python). Look in the
tools/hook-scripts subdir.

I use svnperms.py in my pre-commit hook to easily enforce who can add,
remove and update, and where. It's so flexible (yes, regexes) that you
can say user-so-and-so can add new tags under /tags/ but not add under,
/tags/*/ (I.e. could create /tags/v1.4/ but not mess up /tags/v1.3 by
adding /tags/v1.3/newdir/).

Since these scripts are a pre-commit business you're still stuck with
per-user granularity to control read access.

-Nathan

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Sat Sep 4 07:39:10 2004

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.