CODETOOLS-7900327: Change webrev to use 'trees' instead of 'forest'

Daniel Fuchs daniel.fuchs at oracle.com
Mon Mar 17 14:40:14 UTC 2014


Hi Roger,

Here is a new webrev. It attempts to detect whether the trees
extension is present by calling 'hg help trees' - and assuming that
a non-zero error status means that trees are not configured.

Also - I modified the places where I added calls to
   hgroot=`hg root`
by
   hgroot=`hg root | $FILTER`

as it seems it would be needed for cygwin.

http://cr.openjdk.java.net/~dfuchs/webrev_CODETOOLS-7900327/webrev.01/

Note: the new additions (webrev.01) have been tested only on Mac.
It would be good if someone could try this patch on windows/cygwin.
I'm not sure anybody did that yet.

best regards,

-- daniel


On 3/17/14 2:05 PM, roger riggs wrote:
> Hi Daniel,
>
> What error messages are generated if the tree extension is not configured?
> Should there be something in the usage to advise the correct preconditions?
>
> Roger
>
> On 3/17/2014 5:38 AM, Daniel Fuchs wrote:
>> Hi,
>>
>> I would like to propose a patch for fixing
>>
>> CODETOOLS-7900327: Change webrev to use 'trees' instead of 'forest'
>> https://bugs.openjdk.java.net/browse/CODETOOLS-7900327
>>
>> webrev:
>> http://cr.openjdk.java.net/~dfuchs/webrev_CODETOOLS-7900327/webrev.00/
>>
>> (I will need a sponsor)
>>
>> This patch changes the behavior of the '-f' option, so that it relies
>> on 'trees' [1] instead of 'forest'.
>> For this to work your forest needs to have been configured for trees.
>> This happens automatically if you used 'hg tclone' to clone it,
>> but otherwise you can call 'hg tconfig --set --walk --depth' to
>> configure it (you can use 'hg tlist' to see the list of trees
>> that have been configured).
>>
>> The main changes in the patch (trickiest) comes from the
>> fact that whereas hg f<cmd> used to print '[<relative-path>]'
>> hg t<cmd> now prints '[<full-path>]:'
>>
>>
>> I tested the patch with the following options:
>>
>> [all files edited, no commit]:
>>
>> webrev -fN
>>
>> [all files committed, no edits]:
>>
>> webrev -f
>>
>> best regards,
>>
>> -- daniel
>> [1] http://openjdk.java.net/projects/code-tools/trees/
>>
>>> Hi Daniel;
>>>
>>> Since it looks like several people have tried your patch and seem to
>>> find it works for them then perhaps you should just create a
>>> CODETOOLS issue and propose it to this list (webrev-dev) for
>>> sponsorship.
>>>
>>> I haven't had a chance to try it yet but likely wouldn't have
>>> anything to add by my review (and I am not a committer/reviewer on
>>> CODETOOLS) so I would encourage you to go ahead with proposing it
>>> yourself.
>>>
>>> Cheers,
>>>
>>> Mike
>>
>>
>>
>



More information about the webrev-dev mailing list