~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/annotate.py

MergeĀ fromĀ mainine.

Show diffs side-by-side

added added

removed removed

Lines of Context:
55
55
def _annotate_file(branch, rev_id, file_id ):
56
56
 
57
57
    rh = branch.revision_history()
58
 
    w = branch.weave_store.get_weave(file_id, branch.get_transaction())
 
58
    w = branch.repository.weave_store.get_weave(file_id, 
 
59
        branch.repository.get_transaction())
59
60
    last_origin = None
60
61
    for origin, text in w.annotate_iter(rev_id):
61
62
        text = text.rstrip('\r\n')
64
65
        else:
65
66
            last_origin = origin
66
67
            line_rev_id = w.idx_to_name(origin)
67
 
            if not branch.has_revision(line_rev_id):
 
68
            if not branch.repository.has_revision(line_rev_id):
68
69
                (revno_str, author, date_str) = ('?','?','?')
69
70
            else:
70
71
                if line_rev_id in rh:
71
72
                    revno_str = str(rh.index(line_rev_id) + 1)
72
73
                else:
73
74
                    revno_str = 'merge'
74
 
            rev = branch.get_revision(line_rev_id)
 
75
            rev = branch.repository.get_revision(line_rev_id)
75
76
            tz = rev.timezone or 0
76
77
            date_str = time.strftime('%Y%m%d', 
77
78
                                     time.gmtime(rev.timestamp + tz))