~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/push.py

  • Committer: Vincent Ladeuil
  • Date: 2012-02-14 17:22:37 UTC
  • mfrom: (6466 +trunk)
  • mto: This revision was merged to the branch mainline in revision 6468.
  • Revision ID: v.ladeuil+lp@free.fr-20120214172237-7dv7er3n4uy8d5m4
Merge trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
92
92
                revision_id=revision_id, stacked_on=stacked_on,
93
93
                create_prefix=create_prefix, use_existing_dir=use_existing_dir,
94
94
                no_tree=no_tree)
 
95
        except errors.AlreadyControlDirError, err:
 
96
            raise errors.BzrCommandError(gettext(
 
97
                "Target directory %s already contains a .bzr directory, "
 
98
                "but it is not valid.") % (location,))
95
99
        except errors.FileExists, err:
96
 
            if err.path.endswith('/.bzr'):
97
 
                raise errors.BzrCommandError(gettext(
98
 
                    "Target directory %s already contains a .bzr directory, "
99
 
                    "but it is not valid.") % (location,))
100
100
            if not use_existing_dir:
101
101
                raise errors.BzrCommandError(gettext("Target directory %s"
102
102
                     " already exists, but does not have a .bzr"