~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/branch.py

  • Committer: mbp at sourcefrog
  • Date: 2005-03-24 00:13:07 UTC
  • Revision ID: mbp@sourcefrog.net-20050324001307-90a30f7939a6a6f6
- split info command out into separate file

Show diffs side-by-side

added added

removed removed

Lines of Context:
480
480
                            state = 'A'
481
481
                        elif (old_ie.name == entry.name
482
482
                              and old_ie.parent_id == entry.parent_id):
 
483
                            state = 'R'
 
484
                        else:
483
485
                            state = 'M'
484
 
                        else:
485
 
                            state = 'R'
486
486
 
487
487
                        show_status(state, entry.kind, quotefn(path))
488
488
 
542
542
        mutter("committing patch r%d" % (self.revno() + 1))
543
543
 
544
544
        mutter("append to revision-history")
545
 
        f = self.controlfile('revision-history', 'at')
546
 
        f.write(rev_id + '\n')
547
 
        f.close()
 
545
        self.controlfile('revision-history', 'at').write(rev_id + '\n')
548
546
 
549
 
        if verbose:
550
 
            note("commited r%d" % self.revno())
 
547
        mutter("done!")
551
548
 
552
549
 
553
550
    def get_revision(self, revision_id):
767
764
    >>> isdir(bd)
768
765
    False
769
766
    """
770
 
    def __init__(self, files=[], dirs=[]):
 
767
    def __init__(self, files = []):
771
768
        """Make a test branch.
772
769
 
773
770
        This creates a temporary directory and runs init-tree in it.
775
772
        If any files are listed, they are created in the working copy.
776
773
        """
777
774
        Branch.__init__(self, tempfile.mkdtemp(), init=True)
778
 
        for d in dirs:
779
 
            os.mkdir(self.abspath(d))
780
 
            
781
775
        for f in files:
782
776
            file(os.path.join(self.base, f), 'w').write('content of %s' % f)
783
777