[MERGE REVIEW] All ini files as utf-8

Robey Pointer robey at lag.net
Mon Mar 6 02:42:10 GMT 2006


On 3 Mar 2006, at 17:31, Aaron Bentley wrote:

> |>This patch updates the config parsing to treat the config data as  
> utf-8.
> |> This should fix the problems reported by Erik Bågfors and Carlos
> |>Perelló Marín.

Hooray!  I'm +1 on this because it makes the 'whoami' patch possible,  
or at least closer.  (It currently relies on John's encodings branch,  
which may not be finished anytime soon.)

> === modified file 'a/bzrlib/tests/test_config.py'
> --- a/bzrlib/tests/test_config.py	
> +++ b/bzrlib/tests/test_config.py	
> @@ -1,3 +1,4 @@
> +# -*- coding: utf-8 -*-
>  # Copyright (C) 2005 by Canonical Ltd
>  #   Authors: Robert Collins <robert.collins at canonical.com>
>  #
> @@ -30,7 +31,7 @@
>
>  sample_long_alias="log -r-15..-1 --line"
>  sample_config_text = ("[DEFAULT]\n"
> -                      "email=Robert Collins <robertc at example.com>\n"
> +                      u"email=Erik Bågfors <erik at bagfors.nu>\n"
>                        "editor=vim\n"
>                        "gpg_signing_command=gnome-gpg\n"
>                        "log_format=short\n"

I don't know how good everyone's editor is, so maybe it won't be a  
problem converting the file to utf8.  However, you can get the same  
effect by using a unicode \uxxxx escape and leaving the file in ascii.

robey





More information about the bazaar mailing list