~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/log.py

  • Committer: John Arbash Meinel
  • Date: 2007-07-02 15:01:18 UTC
  • mfrom: (2466.11.2 merge_deltas)
  • mto: This revision was merged to the branch mainline in revision 2570.
  • Revision ID: john@arbash-meinel.com-20070702150118-ypa1als5c0dx61ll
(Kent Gibson) 'bzr log --verbose' shows deltas for merged revisions.

Show diffs side-by-side

added added

removed removed

Lines of Context:
269
269
    def iter_revisions():
270
270
        # r = revision, n = revno, d = merge depth
271
271
        revision_ids = [r for r, n, d in view_revisions]
272
 
        zeros = set(r for r, n, d in view_revisions if d == 0)
273
272
        num = 9
274
273
        repository = branch.repository
275
274
        while revision_ids:
276
275
            cur_deltas = {}
277
276
            revisions = repository.get_revisions(revision_ids[:num])
278
277
            if generate_delta:
279
 
                delta_revisions = [r for r in revisions if
280
 
                                   r.revision_id in zeros]
281
 
                deltas = repository.get_deltas_for_revisions(delta_revisions)
282
 
                cur_deltas = dict(izip((r.revision_id for r in 
283
 
                                        delta_revisions), deltas))
 
278
                deltas = repository.get_deltas_for_revisions(revisions)
 
279
                cur_deltas = dict(izip((r.revision_id for r in revisions),
 
280
                                       deltas))
284
281
            for revision in revisions:
285
 
                # The delta value will be None unless
286
 
                # 1. verbose is specified, and
287
 
                # 2. the revision is a mainline revision
288
282
                yield revision, cur_deltas.get(revision.revision_id)
289
283
            revision_ids  = revision_ids[num:]
290
284
            num = min(int(num * 1.5), 200)
551
545
            for l in message.split('\n'):
552
546
                print >>to_file,  indent+'  ' + l
553
547
        if revision.delta is not None:
554
 
            revision.delta.show(to_file, self.show_ids)
 
548
            revision.delta.show(to_file, self.show_ids, indent=indent)
555
549
 
556
550
 
557
551
class ShortLogFormatter(LogFormatter):