/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/upgrade.py

  • Committer: Martin Pool
  • Date: 2009-01-16 02:49:35 UTC
  • mto: This revision was merged to the branch mainline in revision 3945.
  • Revision ID: mbp@sourcefrog.net-20090116024935-3jp2s7dqelxvk1io
Move backup progress indicators from upgrade.py into backup_bzrdir, and tweak text

Show diffs side-by-side

added added

removed removed

Lines of Context:
63
63
                           self.bzrdir._format)
64
64
        self.bzrdir.check_conversion_target(self.format)
65
65
        self.pb.note('starting upgrade of %s', self.transport.base)
66
 
        self._backup_control_dir()
 
66
        self.bzrdir.backup_bzrdir()
67
67
        while self.bzrdir.needs_format_conversion(self.format):
68
68
            converter = self.bzrdir._format.get_converter(self.format)
69
69
            self.bzrdir = converter.convert(self.bzrdir, self.pb)
70
70
        self.pb.note("finished")
71
71
 
72
 
    def _backup_control_dir(self):
73
 
        self.pb.note('making backup of tree history')
74
 
        old_path, new_path = self.bzrdir.backup_bzrdir()
75
 
        self.pb.note('%s has been backed up to %s', old_path, new_path)
76
 
        self.pb.note('if conversion fails, you can move this directory back to .bzr')
77
 
        self.pb.note('if it succeeds, you can remove this directory if you wish')
78
72
 
79
73
def upgrade(url, format=None):
80
74
    """Upgrade to format, or the default bzrdir format if not supplied."""