Show More
@@ -379,15 +379,21 b' def annotate(ui, repo, *pats, **opts):' | |||
|
379 | 379 | change = repo.changelog.read(node) |
|
380 | 380 | mmap = repo.manifest.read(change[0]) |
|
381 | 381 | for src, abs, rel in walk(repo, pats, opts): |
|
382 | if abs not in mmap: | |
|
383 | ui.warn("warning: %s is not in the repository!\n" % rel) | |
|
384 | continue | |
|
385 | ||
|
382 | 386 | lines = repo.file(abs).annotate(mmap[abs]) |
|
383 | 387 | pieces = [] |
|
384 | 388 | |
|
385 | 389 | for o, f in opmap: |
|
386 | 390 | if opts[o]: |
|
387 | 391 | l = [f(n) for n, dummy in lines] |
|
392 | if l: | |
|
388 | 393 | m = max(map(len, l)) |
|
389 | 394 | pieces.append(["%*s" % (m, x) for x in l]) |
|
390 | 395 | |
|
396 | if pieces: | |
|
391 | 397 | for p, l in zip(zip(*pieces), lines): |
|
392 | 398 | ui.write("%s: %s" % (" ".join(p), l[1])) |
|
393 | 399 |
General Comments 0
You need to be logged in to leave comments.
Login now