fix unicode with YAML::Syck
authorJoey Hess <joey@gnu.kitenet.net>
Wed, 24 Mar 2010 20:19:50 +0000 (16:19 -0400)
committerJoey Hess <joey@gnu.kitenet.net>
Wed, 24 Mar 2010 20:19:50 +0000 (16:19 -0400)
Syck-- it doesn't use unicode by default?! Hello, 2010 calling..

IkiWiki/Setup/Yaml.pm
ikiwiki.in

index 8b876e297527af0de21bb8e70d63e5ddcbfdd14e..904784728e0a0cbc6314cf26006010b5e5d25d8a 100644 (file)
@@ -13,6 +13,7 @@ sub loaddump ($$) {
        eval q{use YAML::Any};
        eval q{use YAML} if $@;
        die $@ if $@;
+       $YAML::Syck::ImplicitUnicode=1;
        IkiWiki::Setup::merge(Load($content));
 }
 
index 1758399ea83e0380a4cc90337c5a3edfe0135327..b62962ad8892841b9c28b0c649345514e493f5e1 100755 (executable)
@@ -103,6 +103,7 @@ sub getconfig () {
                                }
                                eval q{use YAML::Any};
                                eval q{use YAML} if $@;
+                               $YAML::Syck::ImplicitUnicode=1;
                                die $@ if $@;
                                $config{$var}=Load($val."\n");
                        },