~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/commands.py

  • Committer: Vincent Ladeuil
  • Date: 2008-10-02 06:18:42 UTC
  • mfrom: (3757 +trunk)
  • mto: This revision was merged to the branch mainline in revision 3759.
  • Revision ID: v.ladeuil+lp@free.fr-20081002061842-4ctag1pkr7ua9gu2
Fix conflict. Related to moved lines, nice use case

Show diffs side-by-side

added added

removed removed

Lines of Context:
43
43
    errors,
44
44
    option,
45
45
    osutils,
46
 
    registry,
47
46
    trace,
48
47
    win32utils,
49
48
    )
50
49
""")
51
50
 
52
 
from bzrlib.symbol_versioning import (
53
 
    deprecated_function,
54
 
    deprecated_method,
55
 
    )
 
51
from bzrlib import registry
56
52
# Compatibility
57
53
from bzrlib.option import Option
58
54
 
765
761
    if not opt_no_aliases:
766
762
        alias_argv = get_alias(argv[0])
767
763
        if alias_argv:
768
 
            alias_argv = [a.decode(bzrlib.user_encoding) for a in alias_argv]
 
764
            user_encoding = osutils.get_user_encoding()
 
765
            alias_argv = [a.decode(user_encoding) for a in alias_argv]
769
766
            argv[0] = alias_argv.pop(0)
770
767
 
771
768
    cmd = argv.pop(0)
835
832
        from bzrlib import symbol_versioning
836
833
        symbol_versioning.suppress_deprecation_warnings(override=False)
837
834
    try:
838
 
        argv = [a.decode(bzrlib.user_encoding) for a in argv[1:]]
 
835
        user_encoding = osutils.get_user_encoding()
 
836
        argv = [a.decode(user_encoding) for a in argv[1:]]
839
837
    except UnicodeDecodeError:
840
838
        raise errors.BzrError(("Parameter '%r' is unsupported by the current "
841
839
                                                            "encoding." % a))