Hi,<br>
<br>
<div><span class="gmail_quote">On 8/14/06, <b class="gmail_sendername">John Arbash Meinel</b> <<a href="mailto:john@arbash-meinel.com">john@arbash-meinel.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Matthieu Moy wrote:<br>> Hi,<br>><br>> In the past, I've brought this topic several times in this mailing<br>> list. The basic problem is that the revision specifiers do not allow<br>> one to deal with a remote revision. The typical problem is: take two
<br>> arbitrary remote revisions. bzrlib knows how to diff them, but up to<br>> recently, it was not exported in the UI at all.<br>><br>> There are roughly 3 ways to deal with it:<br>><br>> 1) Extend the revisionspec to deal with remote locations. That's what
<br>> I implemented allowing one to do "diff -r revno:42:<a href="http://branch.com/">http://branch.com/</a>"<br>><br>> 2) Extend URL to deal with revisions. There used to be a syntax for<br>> this which has been pulled out (
<a href="http://location.com/path/@3">http://location.com/path/@3</a> IIRC)<br>><br>> 3) Keep URL and revision spec distinct, and ask both to be provided on<br>> the command line.</blockquote><div><br>
Getting into discussion late, and i see it already slipped into
discussing (1) way, extend the revisionspec to deal with remote
locations. As far as it goes, i see there are encoding/decoding issues that only complicate things.<br>
I am, as a user, personally inclined to the (3) way, keep URL and revisionspec distinct.<br>
This would get rid of yet another encoding scheme while all that is
needed is to pass two strings into program. IMO trying to join the
strings and thinking of a way how to do it unambiguously is not the way
to go.<br>
<span class="gmail_quote"></span></div><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">> Well, the conclusion is that it's hard to get something easy to type
<br>> (no shell metacharacters) and unambiguous. Indeed, with branch:, there<br>> are already ambiguities: I can have a branch whose name is<br>> "foo..revid:bar", it's a valid directory name!<br><br>...
<br><br>> $ bzr diff -r 3 -R 4 <a href="http://remote/branch">http://remote/branch</a><br>><br>><br>> I'm willing to spend some time on an implementation if the team agrees<br>> on a specification.<br>>
<br>> Any comments/flames/better proposals are welcome.<br><br>Especially with switching over to optparse, you will need to be careful<br>if you want to create an argument that takes 2 parameters. If you really<br>wanted, you could just use ' ' as the separator. So you would have:
<br><br>bzr diff -??? "3 <a href="http://remote/branch">http://remote/branch</a>"<br><br>space can occur in paths, though :)</blockquote><div><br>
I can think of one more way of specifying branch:<br>
(given the "-b" switch is for specifying branch)<br>
<br>
bzr diff -r 3 -b <a href="http://remote/branch">http://remote/branch</a> -r 4 -b <a href="http://somewhere/else">http://somewhere/else</a><br>
</div><br>
This scheme does not use arguments with two parameters, does not need
anything escaped and is clear to type and read. However it requires
parsing of repeated options.<br>
<br>
Just my two cents,<br>
--<br>
ghozzy<br></div>