-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Wednesday, March 4 at 05:01 PM, quoth [email protected]:
> ~h '^Envelope-to: [email protected]'
>
>works when I'm limiting messages once inside the folder, but
>
>score '~h '^Envelope-to: [email protected]'' 41
>
>in my .muttrc doesn't.
Obviously. It gets parsed as the strings:
score
~h ^Envelope-to:
[email protected]
41
The reason is that each ' terminates the quoted string before it. If
you want embedded quotes, you either have to escape them (which is
annoying) or you have to use a different kind of quote for the
embedded version. For example, this would work:
score '~h "^Envelope-to: [email protected]"' 41
The difference is that mutt's parser will see that as the following
strings:
score
~h "^Envelope-to: [email protected]"
41
If you had replaced ALL single quotes with double quotes, e.g.:
score "~h "^Envelope-to: [email protected]"" 41
That would get parsed the exact same way as having all of the quotes
be single quotes. The key is *mixing* the quotes. You could also use
double-quotes for the outside string, and it would still work, like
so:
score "~h '^Envelope-to: [email protected]'" 41
Here's what I mean by escaping quotes:
score "~h \"^Envelope-to: [email protected]\"" 41
That way you're telling mutt which quotes should be considered to end
the string and which are instead *part* of the string. When they're
read, the backslashes get stripped off, so mutt sees that line like
this:
score
~h "^Envelope-to: [email protected]"
41
Does that make sense?
~Kyle
- --
University politics are vicious precisely because the stakes are so
small.
-- Henry Kissinger
-----BEGIN PGP SIGNATURE-----
Comment: Thank you for using encryption!
iEYEARECAAYFAkmuqdMACgkQBkIOoMqOI16PmgCfVYPBOHu6csh/Cwtgrg/k5BfJ
g84AoJywxgHQFZ+FUxdA7suR6oYYNW+C
=feZJ
-----END PGP SIGNATURE-----