~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-14 11:14:25 UTC
  • mfrom: (6207.3.11 use-controldir)
  • Revision ID: pqm@pqm.ubuntu.com-20111014111425-c7nzqujggvlsd9zz
(jelmer) Move static/class methods from BzrDir to ControlDir. (Jelmer
 Vernooij)

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
 
    bzrdir,
 
20
    controldir,
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 = bzrdir.BzrDir.open_from_transport(to_transport)
 
82
        dir_to = controldir.ControlDir.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 bzrdir but no branch or repository
 
153
            # we have a controldir 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"