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

Re: svn diff - unexpected results

From: Ryan Schmidt <subversion-2007a_at_ryandesign.com>
Date: 2007-01-26 07:50:21 CET

On Jan 25, 2007, at 16:45, Jim Thompson wrote:

> 1) diff older and newer tags.
> svn diff .../tags/rel_20070124_1835 .../tags/rel_20070124_1842
> Index: part1.txt
> ===================================================================
> --- part1.txt (.../rel_20070124_1835) (revision 1661)
> +++ part1.txt (.../rel_20070124_1842) (revision 1661)
> @@ -1 +0,0 @@
> -This is part 1 of portlet2a
> ...
> Index: part4.txt
> ===================================================================
> --- part4.txt (.../rel_20070124_1835) (revision 0)
> +++ part4.txt (.../rel_20070124_1842) (revision 1661)
> @@ -0,0 +1,2 @@
> +This is part 4 of portlet2a
> +It replaces part1, which was deleted.
>
> = = = = = = = = = = = = = = = = = = = =
>
> 2) diff newer and older tags (reversed order of diff).
> svn diff .../tags/rel_20070124_1842 .../tags/rel_20070124_1835
> Index: part4.txt
> ===================================================================
> --- part4.txt (.../rel_20070124_1842) (revision 1661)
> +++ part4.txt (.../rel_20070124_1835) (revision 1661)
> @@ -1,2 +0,0 @@
> -This is part 4 of portlet2a
> -It replaces part1, which was deleted.
> Index: part1.txt
> ===================================================================
> --- part1.txt (.../rel_20070124_1842) (revision 0)
> +++ part1.txt (.../rel_20070124_1835) (revision 1661)
> @@ -0,0 +1 @@
> +This is part 1 of portlet2a
> Index: part2.txt
>
> My questions:
>
> 1) What's up with "revision 0" ?
> It only shows when the file in question doesn't exist in the first
> tag compared.
> When the file doesn't exist in the second tag, shouldn't it be
> shown as "revision 0"?

I'm afraid I don't know the answer here.

> 2) What's up with "revision 1661"?
> This is the latest rev number in the repo. It's not when either
> tag was committed. Each time I run a diff, the latest rev number
> shows up. Shouldn't these be something more useful, like the revs
> when each tag was committed (if the file exists with that tag)?

Intended behavior. You did not specify a revision number in your diff
command, therefore you are getting the HEAD revision, which is
currently 1661. In revision 1661, your tags do indeed look the way
Subversion has shown. The fact that a particular tag was last changed
at a different prior revision is a different question, and can be
asked in a different way (for example, "svn info url://to/your/tag"
and examine the "Last Changed Revision" line).

-- 
To reply to the mailing list, please use your mailer's Reply To All  
function
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Fri Jan 26 07:50:50 2007

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