Commit 269e8e4b authored by Eric S. Raymond's avatar Eric S. Raymond

Fix staistics reporting from tagify.

parent 24038503
......@@ -4998,7 +4998,7 @@ def named(self, ref):
date = Date(date)
datematch = lambda t: t == date
except Fatal:
except (Fatal, ValueError):
date = calendar.timegm(time.strptime(date, b"%Y-%m-%d"))
datematch = lambda t: t.timestamp >= date and t.timestamp < date + 24*60*60
......@@ -9960,13 +9960,14 @@ def do_tagify(self, line):
with RepoSurgeon.LineParse(line) as parse:
if parse.line:
raise Recoverable(b"too many arguments for tagify.")
before = len([repo.commits()])
before = len([c for c in repo.commits()])
commits = self.selection,
canonicalize = "--canonicalize" in parse.options,
tipdeletes = "--tipdeletes" in parse.options,
tagify_merges = "--tagify-merges" in parse.options)
announce("%d commits tagified." % (len([repo.commits()]) - before))
after = len([c for c in repo.commits()])
announce("%d commits tagified." % (before - after))
def help_merge(self):
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment