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

Re: svn status -v

From: Branko Čibej <brane_at_xbc.nu>
Date: 2006-08-14 09:43:58 CEST

Tanaka Akira wrote:
> Hi. I found a curious result of svn status -v.
>
> 1. create a repository and checkout it.
>
> | nute% cd /tmp
> | nute% rm -rf r w
> | nute% svnadmin create /tmp/r
> | nute% svn co file:///tmp/r w
> | Checked out revision 0.
> | nute% cd /tmp/w
>
> 2. create d1 and d1/f.
>
> | nute% mkdir d1
> | nute% echo 1 > d1/f
> | nute% svn add d1
> | A d1
> | A d1/f
> | nute% svn commit -m mesg
> | Adding d1
> | Adding d1/f
> | Transmitting file data .
> | Committed revision 1.
>
> 3. copy d1 to d2.
>
> | nute% svn cp d1 d2
> | A d2
> | nute% svn commit -m mesg
> | Adding d2
> |
> | Committed revision 2.
>
> 4. the committed revision of d2/f is 2.
>
> | nute% svn up
> | nute% svn status -v
> | 2 2 akr .
> | 2 1 akr d1
> | 2 1 akr d1/f
> | 2 2 akr d2
> | 2 2 akr d2/f
>
> 5. update to revision 1, and update to revision 2.
>
> | nute% svn up -r 1
> | D d2
> | Updated to revision 1.
> | nute% svn up -r 2
> | A d2
> | A d2/f
> | Updated to revision 2.
>
> 6. the committed revision of d2/f is 1.
>
> | nute% svn status -v
> | 2 2 akr .
> | 2 1 akr d1
> | 2 1 akr d1/f
> | 2 2 akr d2
> | 2 1 akr d2/f
>
> The committed revision of d2/f is changed from 2 to 1.
>
> Is the change is intentional?
>

I agree it's a bit confusing, but it's not really wrong ... the last
"svn status" says that d2/f was last changed in revision 1, which is
true, because it's actually the same file as d1/f. When you committed
the the copy of d1 to d2, the client assumed it was creating a new d2/f,
but that's not what actually happens in the repository. The really
confusing bit is that "svn up -r1 d2/f" will complain that d2/f doesn't
exist in revision 1 ... but that's also true. :)

-- Brane

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon Aug 14 09:44:07 2006

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.