sys.exit(1)
debug = 0
-DEBUG_COMMANDS = 1 # Show commands as they are executed
-DEBUG_PARSE = 2 # Debug logfile parse
+DEBUG_SEQUENCE = 1 # Sequence debugging
+DEBUG_COMMANDS = 2 # Show commands as they are executed
+DEBUG_PARSE = 3 # Debug logfile parse
quiet = False # option -q: run more quietly
pseudotime = False # option -T: artificial clock for regression testing
croak("no current revision? src checkout to recover")
def current_branch(self, reversed=False):
"Return a list of items that are descendants or ancestors of current."
+ if debug >= DEBUG_SEQUENCE:
+ print "current_branch(%s)" % self.current()
p = s = self.native_to_revno(self.current())
selection = [self.by_revno(p)]
while True:
if self.args:
if self.args[0] == "--":
self.args.pop(0)
- elif self.args[0].isdigit():
+ elif self.args[0][0].isdigit():
revspec = self.args.pop(0)
try:
if "-" in revspec or ".." in revspec:
self.seq = [self.start]
s = self.start
while True:
- s = backend.succ(s, self)
+ s = backend.succ(s, metadata)
if s is None:
croak("%s is not an ancestor of %s" % (self.start, self.end))
- selection.append(s)
+ self.seq.append(s)
if s == self.end:
break
+ if debug >= DEBUG_SEQUENCE:
+ sys.stderr.write("selection: %s, branchwise is %s\n" % (self.seq, "on" if self.branchwise else "off"))
+ for item in metadata.revlist:
+ sys.stdout.write("%s\t%s\t%s\n" % (item.revno, item.date, item.revision))
class CommentContext:
def __init__(self, legend, args):