--Kjell H Andersen <firstname.lastname@example.org> wrote:
> That's actually only half the truth.
> By setting svn:needs-lock, the files will be read only when you check
> them out. If you acquire a lock, the file will be read enabled. However,
> if a user decides to make the file writable by using chmod +w (or
> unchecking the Read only tick in Windows), there is nothing that prevents
> him from editing the file and then committing it.
If someone has locked the file, no one else will be able to commit it.
Changing the read-only property of the file in the working copy does not
> The locking mechanism is just for communication between team members.
No, I believe locking a file prevents other people from committing changes
(regardless of the needs-lock property). The needs-lock property serves to
communicate the team policy.
> you encounter a read-only file, the warning lights should flash, and you
> should get a lock on it before doing anything. If a team member fails to
> do that, and edit it anyway, he is undermining the system and may cause
> trouble for his team.
> I would suggest some kind of clever hook script similar to the one that
> prevents tags from being edited.
Another possibility is to make changes in the auto-props section of the
Subversion configuration file on each PC. There you can specify that files
with certain extensions will have the needs-lock property set whenever they
are added to Subversion. The drawback here is that it has to be done on
> Steve Williams wrote:
>> Andrew Bell wrote:
>>> Is there a property or something that I can set so that a file can be
>>> cheked in, once it, won't get committed unless you do something
>>> special, even if you change it?
>> Add the svn:needs-lock property to the file. Then a user needs to get
>> a lock on the file before committing it.
To unsubscribe, e-mail: email@example.com
For additional commands, e-mail: firstname.lastname@example.org
Received on Fri Dec 16 17:48:34 2005