Bug#839593: cme: support (or switch to) UTF-8 encoding

gregor herrmann gregoa at debian.org
Sun Oct 2 14:18:38 UTC 2016


Package: cme
Version: 1.014-1
Severity: wishlist

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

I just tried to help someone to add themselves to Uploaders
programmatically; unfortunately their first name contains a non-ascii
character (the following is a test name, just the 'í' is taken from
the real one).

Both

% cme modify dpkg-control 'source Uploaders:.insort("María Prueba <m at example.org>")'

and

% perl -MConfig::Model=cme -e 'cme("dpkg-control")->modify("source Uploaders:.insort(\"María Prueba <m\@example.org>\")");'

result in a broken 'í', which gets mangled into 'Ã', probably because
perl's default encoding is still latin1.

The following works for me:

% perl -Mutf8 -MConfig::Model=cme -e 'cme("dpkg-control")->modify("source Uploaders:.insort(\"María Prueba <m\@example.org>\")");'

(also with utf8::all but apparently utf8 is enough).


IIRC, files in debian/ should be UTF-8 encoded, so I think it would
make sense to assume UTF-8 as the default encoding, or at least add a
switch to cme(1) or read the encoding from the terminal or something
like this.


Cheers,
gregor

-----BEGIN PGP SIGNATURE-----

iQJ8BAEBCgBmBQJX8Rc+XxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXREMUUxMzE2RTkzQTc2MEE4MTA0RDg1RkFC
QjNBNjgwMTg2NDlBQTA2AAoJELs6aAGGSaoGqrIP/2cOm0SWq0M+ABmWLXIUj0rx
2IwceeaBVbfBlOTUbBR7GkkBkD80cnHQmJ9nI3t+RKwcK6Ey8hGLtvMqQLbiRaBg
Bg/zdlXsIac5YkDIU6/pLjnt3Kez8PWfQlvX8OkZmshXMjTq7XMycBN3UcBGgKnn
bqy8d+OhD3NlC6a/QElZ/4wa0uyUc+obYlXiEyHxfD7rUn4v0UwSlXC9vygylt0u
aVU49kgUWFZvy1ePcGpyrXdg2/Rk50KN+rxD+b/xJNTHOdUu5F80/EdKUWhfz1T7
SmND40RPEdtf3PVxIXoEDky1bRBZVkBWnD5u8eEVNCKfyOBNV+Osg32iJcBe3I9V
BTWCTdeX5Z+P9n7ZPqOAGG1Js2cAEabl0aJNZjHZ4ph8o1p+RtP63cIA2LiP3oFC
CX3RJmmjuYlnhGJZepsqSMmZ8D7ccFOHguKJ4l/0VEfVHV2Xtc3BL2QIHxE1PCIU
UW9j4YeLA7MI8PYwLfzm7eHMZJ/B+fPQvX2px8lzdJ/xn5rNdhUNtZvBZ5mk7SQS
/2tWrh5VT5RUk9MuSrOcVKFRgoYyG+x0eDn5MJJvfRuSyFGN2dqWRg/oXANOBTWQ
BF7h+QTvWaJlWEhFUW71E3PWeyif0LWsePLRCSOQmvwZggr1MaEqaoOnyaSoLD06
epMa2oGBZYa19YSF+VSu
=LNEo
-----END PGP SIGNATURE-----



More information about the pkg-perl-maintainers mailing list