[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Feature] partial read-only access to CVS repository
From: |
Mark D. Baushke |
Subject: |
Re: [Feature] partial read-only access to CVS repository |
Date: |
Thu, 18 Sep 2003 01:32:24 -0700 |
Dieter Maurer <dieter@handshake.de> writes:
> Dear CVS community,
>
> we would like to use CVS as a tool to manage distributed
> development including external partners.
> These partners need read-only access to a large part of the repository
> but write access only to a small part of the repository.
>
> While "pserver" provides a flexible way to specify read-only
> access to a complete repository, there is no concept of
> "read-only" access to parts of the repository with "write" access
> to a different part.
>
>
> I plan to implement such a concept for CVS by combining two
> already existing CVS features, the hierarchical configuration
> used by e.g. "loginfo" and the "access list" of the underlying RCS.
> More precisely, I plan to
>
> * introduce a new administrative file "writeaccess".
>
> It has a format similar to "loginfo", i.e. a sequence
> of lines consisting of a directory pattern and
> an (optionally empty) user list.
>
> The user list is interpreted as follows:
>
> - an empty list is equivalent to all users (without restriction)
> This is the same interpretation as for the "access list"
> in RCS
>
> - a space separated list of user names
>
> A user must be in this list to perform any modifying
> operation on a RCS file in the matched directory
>
> Directory matching is done in the same way as for "loginfo",
> i.e. the first matching line is effective.
>
> * change modifying cvs commands to determine for the
> affected directory (same way as for "loginfo")
> the corresponding list of users and check whether the
> current user is in this list. An empty list is
> interpreted as "no restriction".
> An error is returned when the user is not in the list.
>
>
> If you are interested, I will provide the modifications for
> inclusion in the CVS core.
>
>
> Comments? Improvements? Advice?
It is already possible to do what you want with no changes to cvs
sources.
You may wish to checkout the contrib/cvs_acls (or contrib/cvs_acls.in)
file as a more reasonable alternative. In typical use, you would
run this script as a part of your commitinfo trigger.
Enjoy!
-- Mark