Re: [PATCH 2/2] send-email: rfc2047-quote subject lines with non-ascii characters
- From
Jeff King <peff@peff.net>
- Date
- Mar 29, 2008, 09:52 UTC
- Message-ID
- <20080329095238.GB21814@coredump.intra.peff.net>
- In-Reply-To
- <200803291038.48847.robin.rosenberg.lists@dewire.com>
On Sat, Mar 29, 2008 at 10:38:48AM +0100, Robin Rosenberg wrote:
Show 7 quoted lines
> The environment variables are only part of the story. There is a langinfo API > for this. See I18N::Langinfo(3pm) that knows about those and something else. > > # perl -e 'require I18N::Langinfo; I18N::Langinfo->import(qw(langinfo > CODESET)); $codeset = langinfo(CODESET()); print "My codeset=". > $codeset."\n";' > My codeset=ISO-8859-15
Hmm, neat. So perhaps it would make sense to just use this value instead of utf-8, and not worry about examining the actual text (since any such examination is at best a guess, anyway)?
Any idea what version of perl started shipping I18N::Langinfo? I couldn't see anything useful from grepping the Changes files.
-Peff
PS Your 'require' is more simply written as 'use I18N::Langinfo qw(langinfo CODESET)', or perhaps even simpler:
perl -MI18N::Langinfo=langinfo,CODESET ...