~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/push.py

  • Committer: Patch Queue Manager
  • Date: 2011-10-06 08:34:03 UTC
  • mfrom: (6191.2.1 843900-url-nameerror)
  • Revision ID: pqm@pqm.ubuntu.com-20111006083403-jnsw0exlirg01aed
(mbp) error message without traceback on invalid ubuntu/debian url (bug
 843900) (Martin Pool)

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
"""UI helper for the push command."""
18
18
 
19
19
from bzrlib import (
20
 
    controldir,
 
20
    bzrdir,
21
21
    errors,
22
22
    revision as _mod_revision,
23
23
    transport,
79
79
    """
80
80
    to_transport = transport.get_transport(location)
81
81
    try:
82
 
        dir_to = controldir.ControlDir.open_from_transport(to_transport)
 
82
        dir_to = bzrdir.BzrDir.open_from_transport(to_transport)
83
83
    except errors.NotBranchError:
84
84
        # Didn't find anything
85
85
        dir_to = None
150
150
                "push to %s. You may want to use dpush instead.") % 
151
151
                    e.target_branch.mapping.vcs.abbreviation)
152
152
        except errors.NoRepositoryPresent:
153
 
            # we have a controldir but no branch or repository
 
153
            # we have a bzrdir but no branch or repository
154
154
            # XXX: Figure out what to do other than complain.
155
155
            raise errors.BzrCommandError(gettext("At %s you have a valid .bzr"
156
156
                " control directory, but not a branch or repository. This"