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

Re: svn diff -r BASE:HEAD upside down in diff titles?

From: Joshua Varner <jlvarner_at_gmail.com>
Date: 2005-09-07 00:09:26 CEST

On 9/6/05, Bob Proulx <bob@proulx.com> wrote:
> Madan U Sreenivasan wrote:
> > Bob Proulx wrote:
> > > svn diff -r 1:2
> > > Index: testfile
> > > ===================================================================
> > > --- testfile (revision 0)
> > > +++ testfile (revision 2)
> > > @@ -0,0 +1,2 @@
> > > +#!/usr/bin/env ruby
> > > +# A ruby script.
> >
> > Am wondering why a revision 0 is coming into the picture...
> I believe the answer is that it is just how new files are encoded.
> The file is a new file. It did not exist in any previous revision.
> The earliest possible revision is revision 0 so that is used to
> represent the start of new files. The revision 2 is where the file
> came into being. I see revision 0 used with regards to new files.
> But take that with caution as I am the one asking the original
> question! :-)

Revision 0 means the object did not exist in that particular
revision (either not yet added, or it had been deleted). I think
this is a bug though. What is probably happening is that, since
the object does not exist in BASE, it is setting the revision
number to 0, which is obviously not the same as the wc, so it
assumes the other one must be the wc's revision number.

The diff is done correctly but the heading is wrong. Attached is a script
reproduce. I think this is a bug, but a minor one. If someone wants
me too I will add this to the Issue Tracker.


To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Received on Wed Sep 7 00:11:08 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.