Re: [PATCH v2] emacs: Turn id:"<message-id>" elements into buttons for notmuch searches

Subject: Re: [PATCH v2] emacs: Turn id:"<message-id>" elements into buttons for notmuch searches

Date: Mon, 17 Oct 2011 15:43:18 +0200

To: Thomas Schwinge

Cc: notmuch@notmuchmail.org

From: Daniel Schoepe


On Mon, 17 Oct 2011 15:11:47 +0200, Thomas Schwinge <thomas@schwinge.name> wrote:
> Ah, of course, right...  Yet, won't yours -- id:\"[^ ]+\" -- match too
> much in this example:
> 
>     Bla, bla, see id:"some@thing"--"some famous quote" is bla.
> 
> How about this one?  id:\(\"?\)[^[:space:]"]+\1

You're right, that isn't recognized correctly. According to RFC 822, the
domain part of a message id (which is just "<" addr-spec ">", where
addr-spec is the syntax for normal mail adresses) may contain double
quotes and any other characters if they are escaped with a \. I think
however, that we don't have to handle all those corner cases in a
feature that is merely for convenience, such as this.

In conclusion I think we should allow non-quoted id:..-links, but not
worry about people having escaped spaces or things like that in their
domain parts. What do you think?

Cheers,
Daniel
part-000.sig (application/pgp-signature)

Thread: