On Tue, Aug 26, 2008 at 10:35 PM, Kyle Wheeler <[EMAIL PROTECTED]> wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > On Tuesday, August 26 at 10:32 PM, quoth Shreevatsa R: >> On Sun, Aug 24, 2008 at 7:24 PM, Christian Ebert <[EMAIL PROTECTED]> wrote: >>> * Kyle Wheeler on Sunday, August 24, 2008 at 16:41:53 -0500 >>>> function reply() { >>>> MID=$1; shift; >>> mutt -e "push '<limit>~i $MID<Enter><group-reply>'" $@ >>>> } >> >> Thanks, everyone. One minor annoyance is when Message-IDs have special >> characters in them, e.g., I tried replying to an email today whose >> Message-ID had '$'s in it. In that case, the $s must be escaped, not >> to \$, but to \\$, as mutt strips off one level of \s, according to >> the manual. I currently simply replace each $ by \\$ and it works, but >> asking just in case there is a well-known answer: is there some >> general solution that mutt users use for escaping a pattern according >> to what mutt wants? > > Skip the escaping, and just use quotes: > > mutt -e "push '<limit>~i "$MID"<Enter><group-reply>'" $@ > > AFAIK quote characters aren't allowed in Message-IDs.
That's probably true, but quotes don't work. Start mutt and do <limit>~i "<[EMAIL PROTECTED]>" and it *won't* match Message-ID: <[EMAIL PROTECTED]>". Neither will ~i '<[EMAIL PROTECTED]>' nor ~i "<[EMAIL PROTECTED]>"; the only things that work are ~i '<[EMAIL PROTECTED]>' or ~i <[EMAIL PROTECTED]> or ~i "<[EMAIL PROTECTED]>" (but not ~i '<[EMAIL PROTECTED]>'). I would consider this behaviour a bug in mutt, probably some would not, so I didn't mention it the last time. Is there a reason things are this way? (A design reason, not "that's how it happens to be implemented".)