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

Re: Revision 2 [was Re: [PATCH] Fix for Issue #1093 (pre-release)]

From: Philip Martin <philip_at_codematters.co.uk>
Date: 2003-10-29 20:51:17 CET

"C. Michael Pilato" <cmpilato@collab.net> writes:

> Nah, that would just complicate things further. My suggestions:
>
> 1. Make the --revision (-r) option *always* talk about the operative
> revision range. That means no more 'svn foo -rM:N path1 path2' as
> an alias for 'svn foo path1@M path2@N' (thankfully... what a
> stupid overloading of a concept that was...)
>
> 2. Make the '@' syntax always talk about the "peg" revision.
>
> 3. The peg revision must always be greater than (younger than) the
> youngest revision in the operative range.

Why rule 3?

> The "peg" revision is the one that is auto-populated in various
> commands with things like 'BASE' or 'WORK' or 'HEAD'. So things like:
>
> svn diff -rM:N wcpath
> svn diff -rM:N repos-url
>
> would do what you expect because under the hood it gets translated to
>
> svn diff -rM:N wcpath@BASE

Does rule 3 apply? i.e. M < BASE and N < BASE?

> svn diff -rM:N repos-url@HEAD

Lets drop rule 3 and try a little scenario:

Rev 1: Add /trunk/foo and /trunk/bar
Rev 2: Modify /trunk/foo
Rev 3: Modify /trunk/bar
Rev 4: Delete /trunk/bar
Rev 5: Copy /trunk/foo to /trunk/bar, delete /trunk/foo
Rev 6: Add /trunk/foo
Rev 7: Modify /trunk/bar
Rev 8: Modify /trunk/foo

Using URLs

  See the rev 2 diff using

    svn diff -r1:3 url://.../trunk/bar
    svn diff -r1:3 url://.../trunk/bar_at_5
    svn diff -r1:3 url://.../trunk/bar_at_HEAD
    svn diff -r1:3 url://.../trunk/foo_at_1
    svn diff -r1:3 url://.../trunk/foo_at_4

  See the rev 3 diff using

    svn diff -r1:3 url://.../trunk/bar_at_1
    svn diff -r1:3 url://.../trunk/bar_at_3

  See the rev 7 diff using

    svn diff -r6:8 url://.../trunk/bar_at_5
    svn diff -r6:8 url://.../trunk/bar_at_HEAD
    svn diff -r6:8 url://.../trunk/foo_at_1
    svn diff -r6:8 url://.../trunk/foo_at_2

  See the rev 8 diff using

    svn diff -r6:8 url://.../trunk/foo_at_6
    svn diff -r6:8 url://.../trunk/foo_at_HEAD

Using working copy paths trunk/foo and trunk/bar at BASE rev 6

   See the rev 2 diff using

     svn diff -r1:3 trunk/bar
     svn diff -r1:3 trunk/bar@BASE
     svn diff -r1:3 trunk/bar@6
     svn diff -r1:3 trunk/bar@HEAD

   See the rev 7 diff using

     svn diff -rBASE:HEAD trunk/bar
     svn diff -rBASE:HEAD trunk/bar@BASE
     svn diff -rBASE:HEAD trunk/bar@6
     svn diff -rBASE:HEAD trunk/bar@HEAD

   See the rev 8 diff using

     svn diff -rBASE:HEAD trunk/foo
     svn diff -rBASE:HEAD trunk/foo@BASE
     svn diff -rBASE:HEAD trunk/foo@6
     svn diff -rBASE:HEAD trunk/foo@HEAD

Looks good so far, but what about these

   svn diff -r1:3 trunk/foo@1
   svn diff -r1:3 trunk/bar@1

Do they show the rev 2 diff, the rev 3 diff, or cause an error?

-- 
Philip Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Oct 29 20:52:08 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.