mercurial/graphmod.py
changeset 8837 d8e3a98018cb
parent 8836 11ff34956ee7
child 8840 d9acbe7b0049
equal deleted inserted replaced
8836:11ff34956ee7 8837:d8e3a98018cb
    39         if fctx.rev() <= start:
    39         if fctx.rev() <= start:
    40             yield (fctx, parents)
    40             yield (fctx, parents)
    41         if fctx.rev() <= stop:
    41         if fctx.rev() <= stop:
    42             break
    42             break
    43         filerev -= 1
    43         filerev -= 1
       
    44 
       
    45 def nodes(repo, nodes):
       
    46     include = set(nodes)
       
    47     for node in nodes:
       
    48         ctx = repo[node]
       
    49         parents = [p.rev() for p in ctx.parents() if p.node() in include]
       
    50         parents.sort()
       
    51         yield (ctx, parents)
    44 
    52 
    45 def graph(repo, start_rev, stop_rev):
    53 def graph(repo, start_rev, stop_rev):
    46     """incremental revision grapher
    54     """incremental revision grapher
    47 
    55 
    48     This generator function walks through the revision history from
    56     This generator function walks through the revision history from