~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/builtins.py

  • Committer: Vincent Ladeuil
  • Date: 2010-02-04 09:41:50 UTC
  • mfrom: (4988.7.2 fix-513063)
  • mto: This revision was merged to the branch mainline in revision 5004.
  • Revision ID: v.ladeuil+lp@free.fr-20100204094150-x33ump3qf7eafx1o
Better error message for bzr bind on and already bound branch

Show diffs side-by-side

added added

removed removed

Lines of Context:
4619
4619
                    'This format does not remember old locations.')
4620
4620
            else:
4621
4621
                if location is None:
4622
 
                    raise errors.BzrCommandError('No location supplied and no '
4623
 
                        'previous location known')
 
4622
                    if b.get_bound_location() is not None:
 
4623
                        raise errors.BzrCommandError('Branch is already bound')
 
4624
                    else:
 
4625
                        raise errors.BzrCommandError('No location supplied '
 
4626
                            'and no previous location known')
4624
4627
        b_other = Branch.open(location)
4625
4628
        try:
4626
4629
            b.bind(b_other)