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

Re: Can someone explain this?

From: Ben Collins-Sussman <sussman_at_collab.net>
Date: 2005-02-02 05:12:47 CET

On Feb 1, 2005, at 9:41 PM, Steve Cohen wrote:

> Why am I seeing this?
>
> $ svn list -v
> 2 scohen 401 Jan 29 12:10 A.java
> 2 scohen 576 Jan 29 12:10 C1.java
> $ svn list -r 16 -v
> 2 scohen 401 Jan 29 12:10 A.java
> 2 scohen 576 Jan 29 12:10 C1.java
> 16 scohen 523 Feb 01 21:17 C2.java
> $ svn info
> Path: .
> URL: http://localhost/svn/myproj/trunk/src/java/org/javactivity/game
> Repository UUID: 875b59a7-d4ee-0310-b223-b1047c1ae206
> Revision: 2
> Node Kind: directory
> Schedule: normal
> Last Changed Author: scohen
> Last Changed Rev: 2
> Last Changed Date: 2005-01-29 12:10:00 -0600 (Sat, 29 Jan 2005)
>
> There are not 2 revisions, there are 16. 16 is the latest. Why are
> both the list command and the info command stuck on the idea that
> revision 2 is the latest, unless revision 16 is specified on the
> command
> line? If I look at the repository through a web server
> (http://localhost/svn/myproj/trunk/src/java/org/javactivity/game), I
> see
> revision 16.
>

I think you're confused about what 'svn ls' does. It shows a
repository listing of a certain revision. Normally one runs it on a
URL:

     svn ls [-r X] URL

The number you see in the first column is the last revision in which
the the file changed, and the last person to change it. Obviously, if
you browse older revisions this way, those numbers are going to get
smaller and smaller.

The main point here, though, is that 'svn ls', like all subcommands,
will grab the URL of '.' if you don't give it a URL.

And amazingly, your '.' directory is at revision 2. Probably because
you've never run 'svn up', and have a whole bunch of mixed revisions in
your working copy. (If this doesn't make sense, read about mixed
revisions in chapter 2.)

So when you run 'svn ls', it's exactly as if you had typed 'svn ls -r2
URL-of-current-dir.'

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Wed Feb 2 05:16:36 2005

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

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