Use iter_commits_and_parents

This commit is contained in:
2024-05-24 14:45:06 +02:00
parent 7896b80c42
commit 7fe3e0f497
2 changed files with 6 additions and 8 deletions

View File

@@ -91,16 +91,13 @@ def commit(args):
def log(args):
oid = args.oid
while oid:
for oid in base.iter_commits_and_parents({args.oid}):
commit = base.get_commit(oid)
print(f"commit {oid}\n")
print(textwrap.indent(commit.message, " "))
print("")
oid = commit.parent
def checkout(args):
base.checkout(args.oid)