~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/commands.py

  • Committer: Martin Pool
  • Date: 2005-06-20 02:50:08 UTC
  • Revision ID: mbp@sourcefrog.net-20050620025008-43e29d64489fe946
- split out a new 'bzr upgrade' command separate from 
  (but based on) 'bzr check', so that the code in each is simpler

Show diffs side-by-side

added added

removed removed

Lines of Context:
1122
1122
    to help ensure data consistency.
1123
1123
    """
1124
1124
    takes_args = ['dir?']
1125
 
    takes_options = ['update']
1126
1125
 
1127
 
    def run(self, dir='.', update=False):
 
1126
    def run(self, dir='.'):
1128
1127
        import bzrlib.check
1129
 
        bzrlib.check.check(Branch(dir), update=update)
 
1128
        bzrlib.check.check(Branch(dir))
 
1129
 
 
1130
 
 
1131
 
 
1132
class cmd_upgrade(Command):
 
1133
    """Upgrade branch storage to current format.
 
1134
 
 
1135
    This should normally be used only after the check command tells
 
1136
    you to run it.
 
1137
    """
 
1138
    takes_args = ['dir?']
 
1139
 
 
1140
    def run(self, dir='.'):
 
1141
        from bzrlib.upgrade import upgrade
 
1142
        upgrade(Branch(dir))
1130
1143
 
1131
1144
 
1132
1145