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

Re: Resolution of 'svn diff' change?

From: Jan Braun <janbraun_at_gmx.de>
Date: 2003-05-20 22:13:59 CEST

Sander Striker wrote:
>
> > From: Greg Hudson [mailto:ghudson@MIT.EDU]
> > Sent: Tuesday, May 20, 2003 8:25 PM
> >
> > On Tue, 2003-05-20 at 13:52, Sander Striker wrote:
> > > Say that some file is called 'C' in my working copy. It was called 'B'
> > > in revision N and 'A' in revision M. Now, what would this do:
> > >
> > > svn diff --old=URL-OF-WC@M --new=URL-OF-WC@N A
>
> I had meant to say: svn diff --old=URL-OF-WC@M --new=URL-OF-WC@N C
> Where C is the file as currently in my working copy. Note that the
> shorthand of this makes the problem a bit clearer:
>
> svn diff -r M:N C
>
> So would my above example give me the diff between B@N and A@M, or would
> it try to do a diff between C@N and ... ?

"C" is interpreted relative to NEW-TARGET, thus it might be
1) between C@M and C@N or
2) between WILL-SOON-BE-RENAMED-TO-C@M and C@N

(...when i make up that there are C and WILL-SOON-BE-RENAMED-TO-C in
rev M, and C gets deleted and WILL-SOON-BE-RENAMED-TO-C moved to C
before rev N)

Currently, diff does 1), which is why I wrote "below (both) TARGETS"
in my proposal[1].
I'm rather confused now whether 2) could reasonably be implemented and
whether it'd be a good idea to do so...
        Jan

[1] While figuring that out, I stumbled about the following:

svnadmin create repo
svn co file://`pwd`/repo wc
cd wc
echo this is "c" in rev 1 >c
echo this is "will-be-c" in rev 1 >willbec
svn add willbec c
svn ci -m "foo"
svn rm c
svn ci -m "bar"
svn mv willbec c
svn ci -m "baz"
svn diff -r 1 c

Index: c
===================================================================
--- c (revision 1)
+++ c (working copy)
@@ -0,0 +1 @@
+this is will-be-c in rev 1
Index: c
===================================================================
--- c (revision 1)
+++ c (working copy)
@@ -1 +0,0 @@
-this is c in rev 1

These are not only two sets (which i found surprising), but they are
in the wrong order, which makes the composite patch unapplicable to
c@1 (which i think is a bug). Should I file this or go get some sleep?

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue May 20 22:14:56 2003

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.