~abentley/bzrtools/bzrtools.dev

« back to all changes in this revision

Viewing changes to __init__.py

  • Committer: Alexander Belchenko
  • Date: 2006-11-06 08:30:22 UTC
  • mto: This revision was merged to the branch mainline in revision 637.
  • Revision ID: bialix@ukr.net-20061106083022-c80f85f6860ea6c6
refactor r -> repo

Show diffs side-by-side

added added

removed removed

Lines of Context:
20
20
        to_file = self.outf
21
21
 
22
22
        try:
23
 
            r = bzrlib.branch.Branch.open_containing('.')[0].repository
 
23
            repo = bzrlib.branch.Branch.open_containing('.')[0].repository
24
24
        except errors.NotBranchError:
25
25
            try:
26
 
                r = bzrlib.repository.Repository.open('.')
 
26
                repo = bzrlib.repository.Repository.open('.')
27
27
            except errors.NotBranchError:
28
28
                print >>to_file, \
29
29
                      ("You need to run this command "
31
31
                       "or from a branch.")
32
32
                return 3
33
33
 
34
 
        g = r.get_revision_graph()
 
34
        g = repo.get_revision_graph()
35
35
        possible_heads = set(g.keys())
36
36
        not_heads = set()
37
37
        for parents in g.values():
48
48
        
49
49
        for head in heads:
50
50
            print >>to_file, "revision-id:", head
51
 
            rev = r.get_revision(head)
 
51
            rev = repo.get_revision(head)
52
52
            # borrowed from LongLogFormatter
53
53
            print >>to_file,  indent+'committer:', rev.committer
54
54
            try: