[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Locking issues

From: Ben Collins-Sussman <sussman_at_collab.net>
Date: 2005-04-15 19:56:33 CEST

On Apr 14, 2005, at 4:52 PM, Philip Martin wrote:
>
> Can we agree on the behaviour? Earlier in this thread you suggested
> 'svn info -rN wcpath' should show repository locks, does that still
> apply? Given the command 'svn info -rX wcpath@Y' which combination of
> X and Y should show repository locks?
>
> Another problem is that the svn_info_receiver_t callback gets an
> svn_info_t which only contains one lock, so it's not possible for the
> svn info command to show both the working copy and the repository
> lock. Perhaps svn_info_t should be extended to allow both locks?
>

Hm, I don't think it needs to be so complex. The svn_info_t structure
*either* is talking about a working-copy item, *or* a repository item.
Never a blend of the two things.

So I think that

    svn info wcpath

...is the only case that ever shows information about the thing sitting
right in front of you, right in the working copy. And if a lock-token
happens to be present in the entries file, that will be shown.

The other cases:

    svn info URL
    svn info URL@X
    svn info -rX wcpath
    svn info wcpath@X

...these should all return an svn_info_t structure describing some
object in the repository. We need to be careful when renames are
traced: I think that the remote lock should only be shown if

    1. the object's old path is exactly the same as its current path, and
    2. that same current path is locked.

So, as an example, suppose I have a lock-token in my working copy, and
then run 'svn st -u' and see a code 'T' next to the file. This means
my lock-token isn't just defunct, but somebody stole the lock (broke my
existing one, created a new one). And now I want to see both the
working-copy's and the repository's idea of the lock.

To see my defunct lock-token, I run 'svn info foo.c'. To see the
newest lock in the repository, I run 'svn info foo.c@HEAD' or 'svn info
URL-of-foo'.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Apr 15 19:57:39 2005

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.