--- /dev/null
+Return-Path: <xuwang762@gmail.com>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+ by arlo.cworth.org (Postfix) with ESMTP id 6C4216DE0AF8\r
+ for <notmuch@notmuchmail.org>; Sat, 18 Jul 2015 07:54:35 -0700 (PDT)\r
+X-Virus-Scanned: Debian amavisd-new at cworth.org\r
+X-Spam-Flag: NO\r
+X-Spam-Score: -0.575\r
+X-Spam-Level: \r
+X-Spam-Status: No, score=-0.575 tagged_above=-999 required=5\r
+ tests=[AWL=-0.005, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,\r
+ DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25,\r
+ FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=-0.01,\r
+ RCVD_IN_MSPIKE_WL=-0.01, SPF_PASS=-0.001] autolearn=disabled\r
+Received: from arlo.cworth.org ([127.0.0.1])\r
+ by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024)\r
+ with ESMTP id BbKgAfKBtY7c for <notmuch@notmuchmail.org>;\r
+ Sat, 18 Jul 2015 07:54:33 -0700 (PDT)\r
+Received: from mail-oi0-f46.google.com (mail-oi0-f46.google.com\r
+ [209.85.218.46])\r
+ by arlo.cworth.org (Postfix) with ESMTPS id 8DA436DE0352\r
+ for <notmuch@notmuchmail.org>; Sat, 18 Jul 2015 07:54:33 -0700 (PDT)\r
+Received: by oihq81 with SMTP id q81so86387694oih.2\r
+ for <notmuch@notmuchmail.org>; Sat, 18 Jul 2015 07:54:30 -0700 (PDT)\r
+DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113;\r
+ h=mime-version:in-reply-to:references:date:message-id:subject:from:to\r
+ :content-type; bh=X+8C+i1fhld7Q+Y0zp3hJ+0serYpVaEGWQ8HEnqQ2NI=;\r
+ b=cNM7geR4SwYo5dFWQjLA0VBmZqFE0zPVk1mNCwAq7HSwVQCbTTCpYLbcNCZr9WN1GV\r
+ hU4iMMNLQkBG1YYmaQ9+YpAw73XCdk8gX23ihr1qkDXDBO9te7S/cYPBZRmbq4EXuJnu\r
+ e2ViSFwEnHMJDpks2nIy9S320M/sguWNG2KxoA9IfBgIYFsu9dbsZBeRJNpV81riKwZz\r
+ bNJxFRLQw9xiDMtijbchFvOkWYZqFByhRaERo50jt5r6xmcdOhEtYimvCM9/umDSxaI5\r
+ EgV8Vm4Oi630l6W+HNmmUjHWVYkm+uBhOX8GvbTM1bAS2cFOloxgnAMAVTdyEXMdoHor\r
+ lGyQ==\r
+MIME-Version: 1.0\r
+X-Received: by 10.202.229.66 with SMTP id c63mr17550367oih.57.1437231270434;\r
+ Sat, 18 Jul 2015 07:54:30 -0700 (PDT)\r
+Received: by 10.182.241.167 with HTTP; Sat, 18 Jul 2015 07:54:30 -0700 (PDT)\r
+In-Reply-To: <20150718091139.GB8311@chitra.no-ip.org>\r
+References: <20150717121111.GF25651@chitra.no-ip.org>\r
+ <55A923E9.5070509@imca-cat.org>\r
+ <20150718091139.GB8311@chitra.no-ip.org>\r
+Date: Sat, 18 Jul 2015 10:54:30 -0400\r
+Message-ID:\r
+ <CAJhTkNhQtWbt2-ZudUz4bxC98HOC9W-moUohUDaiDuULNXqb9g@mail.gmail.com>\r
+Subject: Re: Searching for phrases in the body of an email\r
+From: Xu Wang <xuwang762@gmail.com>\r
+To: notmuch@notmuchmail.org\r
+Content-Type: text/plain; charset=UTF-8\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.18\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+ <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch/>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+ <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Sat, 18 Jul 2015 14:54:35 -0000\r
+\r
+On Sat, Jul 18, 2015 at 5:11 AM, Suvayu Ali <fatkasuvayu+linux@gmail.com> wrote:\r
+> Hi Lewis,\r
+>\r
+> On Fri, Jul 17, 2015 at 10:48:57AM -0500, J. Lewis Muir wrote:\r
+>>\r
+>> 1. Perhaps you are remembering the "no plain text" message incorrectly?\r
+>> For example, the message could have referred to "text/plain" or\r
+>> "plaintext" (no space). These would be sufficiently different to not\r
+>> match your grep pattern.\r
+>\r
+> True, but my puzzlement is notmuch shouldn't return those results in the\r
+> first place, since I provided a quoted string: "plain text", unless of\r
+> course I need to escape the quotes. Okay, just checked it, doesn't make\r
+> a difference in the number of hits from notmuch.\r
+>\r
+>> 2. Perhaps your email client rendered the "no plain text" message when\r
+>> it encountered an email with only a "text/html" content type? In\r
+>> this case, the "no plain text" (or whatever) message would not be\r
+>> present in the email itself since it would be generated by the email\r
+>> client when rendering the email.\r
+>\r
+> This is possible, but I use mutt. As far as I know, it doesn't do\r
+> "smart" things like that. I also recall looking at the mime parts\r
+> individually as I was surprised at the behaviour, and it was indeed a\r
+> useless text/plain part with that message.\r
+>\r
+>> 3. A really long shot, but could a line wrap have occurred after "plain"\r
+>> such that "text" appeared on the next line? Your grep pattern would\r
+>> not match that.\r
+>\r
+> Good point, I tried grepping for this instead: 'plain[[:space:]/]+text',\r
+> no luck.\r
+>\r
+> Thanks for your comments.\r
+>\r
+> Cheers,\r
+>\r
+> --\r
+> Suvayu\r
+\r
+Hi Suvayu,\r
+\r
+First note that I believe notmuch search is case insensitive by\r
+default, so your grep should be case insensitive as well.\r
+\r
+More importantly, I'm not sure how 'no NEAR "plain text" ' syntax is\r
+parsed. Maybe it is parsed as {no NEAR plain} or {text}.\r
+\r
+You would like to search for the exact phrase, correct? How about the\r
+following?\r
+\r
+notmuch search no adj plain adj text\r
+\r
+Best,\r
+\r
+Xu\r