You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Tech Geek <te...@gmail.com> on 2010/10/11 22:49:22 UTC

Permissions to create branches/tags to certain users only

Our repositories lives in /var/lib/svn/ on a Linux server. We use the
following sturcture on per project per repository basis:

/var/lib/svn/projectA/tags/
 /var/lib/svn/projectA/trunk/
 /var/lib/svn/projectA/branches/

 /var/lib/svn/projectB/tags/
 /var/lib/svn/projectB/trunk/
 /var/lib/svn/projectB/branches/

and so on...

We used LDAP authentication method to authorize users.

My question:
We need to give permissions to only certain users to be able to create
branches and tags so that we can restrict all the developers to the trunk
itself.

Thanks.

Re: Permissions to create branches/tags to certain users only

Posted by Tech Geek <te...@gmail.com>.
David:

The standard Python pre-commit hook that comes with Subversion's
> source tarball will do the job.

Are you referring to the files svnperms.conf.example and svnperms.py found
at [1].


> I have a Perl version that does the same thing.
>
Thanks for sharing your scripts. I will take a detailed look into it.

[1] https://svn.apache.org/repos/asf/subversion/trunk/tools/hook-scripts/

Re: Permissions to create branches/tags to certain users only

Posted by David Weintraub <qa...@gmail.com>.
The standard Python pre-commit hook that comes with Subversion's
source tarball will do the job. I have a Perl version that does the
same thing.

Both of these not only will allow you to keep certain people out of a
branch, but can tag a directory as "add-only". That is, you can "add"
to a directory, but can't modify what you add. This allows you to give
users the right to create tags, but not to modify a tag once it was
created.

Mine also allow you to force particular properties to be on certain
types of files (and the value of that property). For example, you
might want to enforce that files with a *.pdf suffix are marked as
binary or that files with a *.sh suffix have svn:eol-style=LF on them.

And, it also allows you to ban certain file names. For example, I
would ban files that contain symbols that are illegal in Windows,
Illegal Windows file names (such as aux.java), spaces in names, and
files ending with an "@" sign.

You can download my hook scripts from
http://dl.dropbox.com/u/433257/new_svn_hooks.zip.

On Mon, Oct 11, 2010 at 6:49 PM, Tech Geek <te...@gmail.com> wrote:
> Our repositories lives in /var/lib/svn/ on a Linux server. We use the
> following sturcture on per project per repository basis:
>
> /var/lib/svn/projectA/tags/
> /var/lib/svn/projectA/trunk/
> /var/lib/svn/projectA/branches/
>
> /var/lib/svn/projectB/tags/
> /var/lib/svn/projectB/trunk/
> /var/lib/svn/projectB/branches/
>
> and so on...
>
> We used LDAP authentication method to authorize users.
>
> My question:
> We need to give permissions to only certain users to be able to create
> branches and tags so that we can restrict all the developers to the trunk
> itself.
>
> Thanks.
>
>



-- 
David Weintraub
qazwart@gmail.com