You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by "D.J. Heap" <dj...@shadyvale.net> on 2005/04/27 02:50:54 UTC
Removing a needs-lock file
Should 'svn rm' require the user to lock the file if it has
svn:needs-lock set?
It kind of seems like it should -- but an 'svn rm' command is not quite
the same as discouraging an external program from modifying/deleting the
file so I'm not sure what the intended behavior is.
DJ
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Removing a needs-lock file
Posted by "D.J. Heap" <dj...@shadyvale.net>.
Brian W. Fitzpatrick wrote:
[snip]
>
> Well, to enforce that would require a somewhat different line of coding
> than we've currently been using...
>
> In any case, I think it's OK that 'svn rm' can delete a file if
> svn:needs-lock is set. The purpose of svn:needs-lock is to act in an
> advisory capacity so as to prevent more than one person from making
> changes to an unmergable file: Your editor should notice that the file
> is read-only and notify you of this (then you can 'svn lock' the file
> and go about your business).
>
> If you 'svn rm' a file with svn:needs-lock and another user actually has
> a lock on the file, your commit will fail. If you 'svn rm' a file and
> no one else has a lock on the file, the nothing's lost.
>
> -Fitz
Yes, I can accept that.
Thanks,
DJ
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: Removing a needs-lock file
Posted by "Brian W. Fitzpatrick" <fi...@collab.net>.
On Apr 26, 2005, at 9:50 PM, D.J. Heap wrote:
> Should 'svn rm' require the user to lock the file if it has
> svn:needs-lock set?
>
> It kind of seems like it should -- but an 'svn rm' command is not
> quite the same as discouraging an external program from
> modifying/deleting the file so I'm not sure what the intended behavior
> is.
Well, to enforce that would require a somewhat different line of coding
than we've currently been using...
In any case, I think it's OK that 'svn rm' can delete a file if
svn:needs-lock is set. The purpose of svn:needs-lock is to act in an
advisory capacity so as to prevent more than one person from making
changes to an unmergable file: Your editor should notice that the file
is read-only and notify you of this (then you can 'svn lock' the file
and go about your business).
If you 'svn rm' a file with svn:needs-lock and another user actually
has a lock on the file, your commit will fail. If you 'svn rm' a file
and no one else has a lock on the file, the nothing's lost.
-Fitz
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org