You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by "Charles E. Doucette" <cd...@med-learn.com> on 2003/12/11 15:55:54 UTC

using diff to compare a working copy against a URL@rev

I created a branch to represent a version of a project that I passed to a vendor.

It appears that we made a change to a file right before giving the vendor a copy
of the project.

Now I am trying to merge the vendor changes
a) back into the branch
b) back into the mainline

In examining the differences, it appears that the vendor somehow has the latest copy of the changed file but the branch does not;
however, I can't be sure because I can't seem to figure out how to use diff.

At the moment, we're using svn 0.32.1 on Windows XP (with SP 1).

I was scared off of using 0.33 with the need to add a post-commit to do deltification
(and we've been too busy trying to finish the project on time to risk further updating for now). I also wasn't sure how to do that
on Windows (I've since seen a post showing how to do that).

Here's the diff help:

usage: 1. diff [-r N[:M]] [--old OLD-TGT] [--new NEW-TGT] [PATH...]
       2. diff -r N:M URL
       3. diff [-r N[:M]] URL1[@N] URL2[@M]

Here's what I tried to do first:

C:\Inetpub\wwwroot\ABFPportalAuthBranch\my> \
svn diff http://mlc-media/repos/trunk/ABFP/ABFPportal/my/portfolio.aspx@485 \
portfolio.aspx

Then I tried this:

C:\Inetpub\wwwroot\ABFPportalAuthBranch\my>svn diff -r 485 --old http://mlc-medi
a/repos/trunk/ABFP/ABFPportal/my/portfolio.aspx portfolio.aspx
svn: RA layer request failed
svn: PROPFIND request failed on '/repos/trunk/ABFP/ABFPportal/my/portfolio.aspx/
portfolio.aspx'
svn: PROPFIND of '/repos/trunk/ABFP/ABFPportal/my/portfolio.aspx/portfolio.aspx'
: 500 Internal Server Error (http://mlc-media)

I'm trying to diff revision 488 of a file in the trunk with the head revision of
the same file on the branch (which is in the current working directory).

How do I do that?

Thanks,
Chuck

p.s.	I must say that having to supply old/new as --old and --new explicitly doesn't seem to make sense to me. I would assume that
if there is only one path argument it's treated as the TO/NEW argument and if there are two (or two revisions) they're treated as
OLD/FROM and TO/NEW arguments. I'd suggest that you revise your diff help to more clearly show the most common usages:
a) diff [PATH]			diff PREV vs. current in WC
b) diff -r N [PATH]		diff rev. N vs. current in WC
c) diff -r N:M [PATH]		diff two revs. in repos (URLs implied by WC path)
d) diff [-r N] URL[@N] PATH   diff URL (with optional rev.) against WC
e) diff [-r N:M] URL1 URL2	diff two URLs in repos


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

Re: using diff to compare a working copy against a URL@rev

Posted by Ben Collins-Sussman <su...@collab.net>.
On Thu, 2003-12-11 at 09:55, Charles E. Doucette wrote:

> I'm trying to diff revision 488 of a file in the trunk with the head revision of
> the same file on the branch (which is in the current working directory).
> 
> How do I do that?

'svn diff' doesn't yet know how to follow renames in history, which is
what you were (reasonably) expecting here.  See issue #1093.

So you need to explicitly compare the two different paths:

  svn diff trunk-path-URL@488 branch-path-URL@HEAD





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