From: Todd Date: Wed, 14 Jan 2015 00:00:23 +0000 (+1800) Subject: [PATCH v2 0/5] Index the content-type of MIME parts X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=ed71b8a383f1f40bae8c58663742294902d7c44e;p=notmuch-archives.git [PATCH v2 0/5] Index the content-type of MIME parts --- diff --git a/9c/e6a369ddde2121fca75b015465396e634f2977 b/9c/e6a369ddde2121fca75b015465396e634f2977 new file mode 100644 index 000000000..11720f265 --- /dev/null +++ b/9c/e6a369ddde2121fca75b015465396e634f2977 @@ -0,0 +1,98 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by olra.theworths.org (Postfix) with ESMTP id D6DBE431FD0 + for ; Tue, 13 Jan 2015 16:01:02 -0800 (PST) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: 2.438 +X-Spam-Level: ** +X-Spam-Status: No, score=2.438 tagged_above=-999 required=5 + tests=[DNS_FROM_AHBL_RHSBL=2.438] autolearn=disabled +Received: from olra.theworths.org ([127.0.0.1]) + by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id nzWUg7ckUuOc for ; + Tue, 13 Jan 2015 16:00:59 -0800 (PST) +Received: from s75.web-hosting.com (s75.web-hosting.com [198.187.31.9]) + (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) + (No client certificate requested) + by olra.theworths.org (Postfix) with ESMTPS id A5D15431FBF + for ; Tue, 13 Jan 2015 16:00:59 -0800 (PST) +Received: from user-69-73-37-128.knology.net ([69.73.37.128]:38910 + helo=localhost.localdomain) + by server75.web-hosting.com with esmtpsa (UNKNOWN:AES128-SHA256:128) + (Exim 4.82) (envelope-from ) + id 1YBBOL-001yjE-Rx; Tue, 13 Jan 2015 19:00:58 -0500 +From: Todd +To: notmuch@notmuchmail.org +Subject: [PATCH v2 0/5] Index the content-type of MIME parts +Date: Tue, 13 Jan 2015 18:00:23 -0600 +Message-Id: <1421193628-2699-1-git-send-email-todd@electricoding.com> +X-Mailer: git-send-email 1.9.1 +In-Reply-To: <8761ce7s16.fsf@nikula.org> +References: <8761ce7s16.fsf@nikula.org> +X-AntiAbuse: This header was added to track abuse, + please include it with any abuse report +X-AntiAbuse: Primary Hostname - server75.web-hosting.com +X-AntiAbuse: Original Domain - notmuchmail.org +X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] +X-AntiAbuse: Sender Address Domain - electricoding.com +X-Get-Message-Sender-Via: server75.web-hosting.com: authenticated_id: + todd@electricoding.com +X-Source: +X-Source-Args: +X-Source-Dir: +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.13 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Wed, 14 Jan 2015 00:01:03 -0000 + + +This set of patches allows for queries for like: + +Find calendar invites +- mimetype:text/calendar or mimetype:application/ics + +Find any image attachments +- mimetype:image + +Find all patches +- mimetype:text/x-patch + +It is a rework of a previous set of patches that now adds a new +database feature, only available in newly created databases, which +indicates that all of the mime parts are indexed. Indexing of new +messages on an existing database should work fine as well, but the +feature won't be enabled via upgrade. + +Code reviews welcome, I'm not familiar with this code base. + +Todd (5): + Add a failing unit test for indexed mime types + Add the NOTMUCH_FEATURE_INDEXED_MIMETYPES database feature + Add indexing for the mimetype term + Update completions for Emacs and bash + Update documentation + + NEWS | 16 ++++++++++++++++ + completion/notmuch-completion.bash | 2 +- + doc/man7/notmuch-search-terms.rst | 6 ++++++ + emacs/notmuch.el | 2 +- + lib/database-private.h | 15 ++++++++++++--- + lib/database.cc | 11 +++++++++-- + lib/index.cc | 6 ++++++ + test/T190-multipart.sh | 32 ++++++++++++++++++++++++++++++++ + 8 files changed, 83 insertions(+), 7 deletions(-) + +-- +1.9.1