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

Re: Some peg rev help text missing from command-line client

From: C. Michael Pilato <cmpilato_at_collab.net>
Date: 2006-05-09 19:54:52 CEST

Daniel Rall wrote:
> Mike, would you mind describing how the use cases for the following
> commands differ?:

Sure, this is the whole reason the peg revision / operative revision syntax
discrimination exists:

> svn switch -r37 http://repos-host/svn/branches/foo

Adding implied values, this is:

   svn switch -r37 http://repos-host/svn/branches/foo@HEAD

So, switch my working copy to the way that the thing that currently (in
HEAD) lives at branches/foo looked back in revision 37 (even though it might
not have lived at branches/foo back in that revision).

> svn switch http://repos-host/svn/branches/foo@37

Adding implied values, this is:

   svn switch -rHEAD http://repos-host/svn/branches/foo@37

So, switch my working copy to the way that the thing that lived at
branches/foo back in revision 37 looks today in HEAD (even though it might
have since been moved to some other place).

See the difference?

There's a little gotcha in the second case in that Subversion can't really
search forward in history, so it just crosses its fingers and says, "I don't
know how to find out definitively where /branches/foo@37 might possible live
in HEAD (which could be multiple places, thanks to copies), but I can at
least see if some fork of that same line of history can still be found at
/branches/foo and, if so, use that."

> I'd have thought both commands were intended to "switch my working copy
> to the 'foo' branch as it looked in r37."

Nuh-uh. See above.

-- 
C. Michael Pilato <cmpilato@collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand

Received on Tue May 9 19:57:33 2006

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