~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/ui/__init__.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2011-08-09 09:04:06 UTC
  • mfrom: (6056.2.3 migrate-config-options)
  • Revision ID: pqm@pqm.ubuntu.com-20110809090406-sjx052uyb3t9c6o0
(vila) Migrate some config options to the stack-based API. (Vincent Ladeuil)

Show diffs side-by-side

added added

removed removed

Lines of Context:
47
47
from bzrlib.lazy_import import lazy_import
48
48
lazy_import(globals(), """
49
49
from bzrlib import (
 
50
    config,
50
51
    osutils,
51
52
    progress,
52
53
    trace,
247
248
        """
248
249
        # XXX: is the caller supposed to close the resulting object?
249
250
        if encoding is None:
250
 
            from bzrlib import config
251
 
            encoding = config.GlobalConfig().get_user_option(
252
 
                'output_encoding')
 
251
            encoding = config.GlobalStack().get('output_encoding')
253
252
        if encoding is None:
254
253
            encoding = osutils.get_terminal_encoding(trace=True)
255
254
        if encoding_type is None: