Re: Interaction between charset variables and alias definitions
- To: mutt-users@xxxxxxxx
- Subject: Re: Interaction between charset variables and alias definitions
- From: Kyle Wheeler <kyle-mutt@xxxxxxxxxxxxxx>
- Date: Thu, 13 Nov 2008 09:53:58 -0600
- Comment: DomainKeys? See http://domainkeys.sourceforge.net/
- Dkim-signature: v=1; a=rsa-sha1; c=relaxed; d=memoryhole.net; h=date :from:to:subject:message-id:mime-version:content-type; s=default ; bh=QFEsEkzyoA8EyKsjpF57P6Eh/rs=; b=gGN4XB/6sxD9HG04pLzQqahUUba 4Bl/hsm2rGyIvC5WZ1oj6u6k7AejPqMX2x1EhutcFhDhLeomzJMW47DCenUj6Sqe J3p0v+vKc3s8R5HWEfoIPdGOAmoQlp0hey8/QUC+KIBW4Ya5XvU+vLTIXMxyErNS g4/hbNB5Zb8xvm00=
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=memoryhole.net; b=VSjFV3EzwmA+9H/2N+NBSkMe8JQavs15tqia+OQeRBds3qdZhOKHrMhtriW0ddUsuX9FyMu+c/Ioj6p96eEXM1ZA0baDXeansnmWhdPQJRTG5W3aK+IXrXZKEvISmHXD/AJgM5vvQJlK4J8iH6evKhQAWmnfg/vC+aN11vyt2r8=; h=Received:Received:Date:From:To:Subject:Message-ID:Mail-Followup-To:MIME-Version:Content-Type:Content-Disposition:OpenPGP:User-Agent;
- List-post: <mailto:mutt-users@mutt.org>
- List-unsubscribe: send mail to majordomo@mutt.org, body only "unsubscribe mutt-users"
- Mail-followup-to: mutt-users@xxxxxxxx
- Openpgp: id=CA8E235E; url=http://www.memoryhole.net/~kyle/kyle-pgp.asc; preference=signencrypt
- Sender: owner-mutt-users@xxxxxxxx
- User-agent: Mutt/1.5.18 (2008-10-30)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Thursday, November 13 at 07:19 PM, quoth Dave Feustel:
>I changed all mutt's charset variables from "utf-8" to
>"utf-8:us-ascii:iso-8859-1" and then mutt reported IDN errors in all of
>my alias definitions. The errors disappeared when I went back to just
>"utf-8". What is the connection between charset and alias in mutt?
Wow, there's *lots* wrong with that! :)
First of all, not all of the charset-related variables accept
colon-separated lists. The ones that do are $assumed_charset,
$attach_charset, and $send_charset. The others, $charset and
$config_charset, are merely the name of a *specific* charset. (Though
you should almost never be explicitly setting $charset anyway.)
The one that is crucial to reading your aliases is $config_charset.
Mutt assumes that you know what charset your config files are in, thus
accepting a list of alternatives is pretty pointless.
And finally, that's a *pointless* list of alternatives even for the
variables that accept colon-separated lists. The way the
colon-separated lists work is that mutt tries each alternative until
it finds one that can encode everything that needs to be encoded.
Utf-8 can ALWAYS encode everything, so mutt will never use anything
else; the rest of the alternatives after it are completely ignored.
The most appropriate charset settings for 99.9% of Western users are
(credit to Alain Bench):
set assumed_charset="windows-1252"
set send_charset="us-ascii:iso-8859-1:iso-8859-15:windows-1252:utf-8"
charset-hook '^x-unknown$' windows-1252
charset-hook '^unknown-8bit$' windows-1252
charset-hook '^iso-8859-1$' windows-1252
charset-hook '^us-ascii$' windows-1252
charset-hook '^none$' windows-1252
charset-hook '^iso-8859-8-i$' iso-8859-8
charset-hook '^gb2313$' gb18030
You may also need to set $config_charset, depending on what character
set you've used to encode mutt's config files. But that's about it.
Does that help?
~Kyle
- --
In order to keep a true perspective of one's importance, everyone
should have a dog that will worship him and a cat that will ignore
him.
-- Dereke Bruce
-----BEGIN PGP SIGNATURE-----
Comment: Thank you for using encryption!
iEYEARECAAYFAkkcRrUACgkQBkIOoMqOI17SfACg4TN6lhmI28h8PLmhcBatONQY
NDkAn1EaFUpaVavhc+VuN5BYeFLQU/JV
=Y5g9
-----END PGP SIGNATURE-----