[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: File group attribute after cvs tagging (for users belongs to two gr

From: Bulgrien, Kevin
Subject: RE: File group attribute after cvs tagging (for users belongs to two groups)
Date: Mon, 11 Sep 2006 09:09:27 -0400

> -----Original Message-----
> I would like to know if you can set the permissions whenever 
> a file is added to the repository.  Right now I have CVS set 
> up so every user operation runs under the user 'cvs'.  I 
> found that if I let it run as the user who is adding/checking 
> in a file it sets the file ownership to their account and 
> then other developers could not make changes. 

It is possible using a loginfo hook script though this sort of
thing will take some work especially if you use 1.11.x and your
users cannot be convinced to avoid spaces in directory/file names.
There may other hook scripts that could be used for this also, but
a working implementation I know if uses loginfo.

In essence:

CVSROOT/loginfo contains something like:

  ALL /path/to/cvs/scripts/ %{sVv}

The is called with the following command-line parameters

  module file1,oldversion,newversion file2,oldversion,newversion ...

When first adding a module, the parameter format may be different:

  module - New directory

To change permissions, just write a script that will detect when the
revision number of a file is 1.1 and when modules are first added.

The script runs as the user doing the commit.  As I said before it
will get hairy if spaces are used in file and directory names.  I
am told that 1.12.x strains of CVS may be easier to work with if
this cannot be avoided (See UseNewInfoFmtStrings).

Kevin R. Bulgrien
Design and Development Engineer


Unless otherwise indicated, all information (including attachments)
contained in this e-mail communication is confidential and proprietary
information exclusively owned by the sender and/or its related or affiliated
companies and shall not, without the prior written consent of the sender, be
used, disclosed, distributed or reproduced, in whole or in part, by anyone
other than the individual or entity to whom this communication is addressed
exclusively for the purpose expressly indicated in this communication.

This e-mail communication is intended for the use of the individual or
entity to whom it is addressed.  If you are not the intended recipient of
this communication, you are hereby notified that any use, dissemination,
distribution or copying of this communication is strictly prohibited.  If
you have received this communication in error, please destroy any copies,
electronic, paper or otherwise that you may have.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]