--- emerge.org 2003-07-20 22:20:10.000000000 +0100 +++ emerge 2003-07-20 23:49:16.000000000 +0100 @@ -970,6 +970,7 @@ def display(self,mylist): changelogs=[] + allmyprint=[] for x in mylist: #print x if x[0]=="blocks": @@ -1072,7 +1073,12 @@ myprint=myprint+myoldbest+" "+iuse else: myprint="["+x[0]+" "+addl+"] "+darkgreen(x[2])+" "+myoldbest+" "+iuse - print myprint + mygraph = self.digraph.copy() + indent="" + for a in range(0,mygraph.depth(string.join(x))): + indent=indent+"-" + + allmyprint.append(indent+myprint) mysplit=portage.pkgsplit(x[2]) # XXX mysplit _can_ be None.... Why? @@ -1095,6 +1101,10 @@ print del mysplit + allmyprint.reverse() + for x in allmyprint: + print x + if "--changelog" in myopts: print for revision,text in changelogs: --- portage.py.org 2003-07-20 22:19:52.000000000 +0100 +++ portage.py 2003-07-21 00:08:57.000000000 +0100 @@ -369,7 +369,14 @@ for x in self.okeys: if self.dict[x][0]==0: return x - return None + return None + + def depth(self, mykey): + depth=0 + while (self.dict[mykey][1]): + depth=depth+1 + mykey=self.dict[mykey][1][0] + return depth def allzeros(self): "returns all nodes with zero references, or NULL if no such node exists"