~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/info.py

  • Committer: jelmer at samba
  • Date: 2011-10-11 12:01:51 UTC
  • mto: This revision was merged to the branch mainline in revision 6214.
  • Revision ID: jelmer@samba.org-20111011120151-l1aa35zasaocrev3
Fix tests and the like.

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
 
23
23
from bzrlib import (
24
24
    bzrdir,
 
25
    controldir,
25
26
    errors,
26
27
    hooks as _mod_hooks,
27
28
    osutils,
336
337
                repository = a_bzrdir.open_repository()
337
338
            except NoRepositoryPresent:
338
339
                # Return silently; cmd_info already returned NotBranchError
339
 
                # if no bzrdir could be opened.
 
340
                # if no controldir could be opened.
340
341
                return
341
342
            else:
342
343
                lockable = repository
451
452
        branch.user_url != tree.user_url):
452
453
        branch = None
453
454
        repository = None
454
 
    non_aliases = set(bzrdir.format_registry.keys())
455
 
    non_aliases.difference_update(bzrdir.format_registry.aliases())
 
455
    non_aliases = set(controldir.format_registry.keys())
 
456
    non_aliases.difference_update(controldir.format_registry.aliases())
456
457
    for key in non_aliases:
457
 
        format = bzrdir.format_registry.make_bzrdir(key)
 
458
        format = controldir.format_registry.make_bzrdir(key)
458
459
        if isinstance(format, bzrdir.BzrDirMetaFormat1):
459
460
            if (tree and format.workingtree_format !=
460
461
                tree._format):
472
473
        return 'unnamed'
473
474
    candidates.sort()
474
475
    new_candidates = [c for c in candidates if not
475
 
        bzrdir.format_registry.get_info(c).hidden]
 
476
        controldir.format_registry.get_info(c).hidden]
476
477
    if len(new_candidates) > 0:
477
478
        # If there are any non-hidden formats that match, only return those to
478
479
        # avoid listing hidden formats except when only a hidden format will