glog output change in current crew

Peter Arrenbrecht peter.arrenbrecht at gmail.com
Sun Nov 16 14:06:46 CST 2008


On Sun, Nov 16, 2008 at 8:51 PM, Peter Arrenbrecht
<peter.arrenbrecht at gmail.com> wrote:
> On Sun, Nov 16, 2008 at 5:05 PM, Bastian Doetsch <bastian.doetsch at gmx.de> wrote:
>> Hi,
>>
>> I fear the recent changes in the glog code have broken it for files.
>> Issuing the following command resulted in different outputs for 1.0.2
>> and crew.
>
> Yes, sorry about that. Seems one of my later fixes didn't quite make
> it into crew. Here's a patch:
>
> diff --git a/hgext/graphlog.py b/hgext/graphlog.py
> --- a/hgext/graphlog.py
> +++ b/hgext/graphlog.py
> @@ -40,7 +40,7 @@
>     filerev = len(repo.file(path)) - 1
>     while filerev >= 0:
>         fctx = repo.filectx(path, fileid=filerev)
> -        parents = [f.filerev() for f in fctx.parents() if f.path() == path]
> +        parents = [f.linkrev() for f in fctx.parents() if f.path() == path]
>         parents.sort()
>         if fctx.rev() <= start:
>             yield (fctx, parents)
>
> Am looking into a test that catches this situation.

Submitted test and fix as proper patchbomb now.
-parren

>>
>> Command:
>>
>> hg glog --config extensions.graphlog= --template "*{rev}\n" .classpath
>>
>> Output with current crew:
>>
>> o  *325
>> |
>> | o  *178
>> | |
>> | | o  *177
>> | | |
>> | | | o  *75
>> | | | |
>> | | | | o  *62
>> | | | | |
>> | | | | o  *0
>> | | | |
>>
>>
>> Output with 1.0.2:
>>
>> o  *325
>> |
>> o  *178
>> |
>> o  *177
>> |
>> o  *75
>> |
>> o  *62
>> |
>> o  *0
>>
>> Best regards,
>> Bastian
>>
>> _______________________________________________
>> Mercurial-devel mailing list
>> Mercurial-devel at selenic.com
>> http://selenic.com/mailman/listinfo/mercurial-devel
>>
>>
>


More information about the Mercurial-devel mailing list