From 15628eea4d48e4015006b1942841f8ad67de14d5 Mon Sep 17 00:00:00 2001 From: Mark Walters Date: Sat, 3 Mar 2012 13:05:13 +0000 Subject: [PATCH] [PATCH 0/5] Move to --with-excluded approach to excludes --- 9f/3207bd8870ba246ad8b225d54e68bb1fac2942 | 122 ++++++++++++++++++++++ 1 file changed, 122 insertions(+) create mode 100644 9f/3207bd8870ba246ad8b225d54e68bb1fac2942 diff --git a/9f/3207bd8870ba246ad8b225d54e68bb1fac2942 b/9f/3207bd8870ba246ad8b225d54e68bb1fac2942 new file mode 100644 index 000000000..54ce99a19 --- /dev/null +++ b/9f/3207bd8870ba246ad8b225d54e68bb1fac2942 @@ -0,0 +1,122 @@ +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 5B796431FBC + for ; Sat, 3 Mar 2012 05:03:45 -0800 (PST) +X-Virus-Scanned: Debian amavisd-new at olra.theworths.org +X-Spam-Flag: NO +X-Spam-Score: 0.201 +X-Spam-Level: +X-Spam-Status: No, score=0.201 tagged_above=-999 required=5 + tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, + FREEMAIL_ENVFROM_END_DIGIT=1, FREEMAIL_FROM=0.001, + RCVD_IN_DNSWL_LOW=-0.7] 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 hY+23c868SUK for ; + Sat, 3 Mar 2012 05:03:43 -0800 (PST) +Received: from mail-wi0-f181.google.com (mail-wi0-f181.google.com + [209.85.212.181]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) + (No client certificate requested) + by olra.theworths.org (Postfix) with ESMTPS id 2C6E9431FAE + for ; Sat, 3 Mar 2012 05:03:43 -0800 (PST) +Received: by wico1 with SMTP id o1so697694wic.26 + for ; Sat, 03 Mar 2012 05:03:40 -0800 (PST) +Received-SPF: pass (google.com: domain of markwalters1009@gmail.com designates + 10.180.103.35 as permitted sender) client-ip=10.180.103.35; +Authentication-Results: mr.google.com; spf=pass (google.com: domain of + markwalters1009@gmail.com designates 10.180.103.35 as permitted + sender) smtp.mail=markwalters1009@gmail.com; + dkim=pass header.i=markwalters1009@gmail.com +Received: from mr.google.com ([10.180.103.35]) + by 10.180.103.35 with SMTP id ft3mr3896275wib.0.1330779820636 (num_hops + = 1); Sat, 03 Mar 2012 05:03:40 -0800 (PST) +DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; + h=from:to:cc:subject:date:message-id:x-mailer; + bh=XiM5XX4fQdyNVLdu+WTboRd5qKfrxG4JlPiD4PIxK5s=; + b=CWS5aayrPwv3tkukoq9fZPZI0NCiDCeH/IsRuKXBBYVE3M6C4+5myxYdUTM/I2u5Y4 + iM3b2bv8+svxn/oARbJC5jrnVntK4mpxdVuQwrmCWmGbepIWHuvKttBq/5SGiHTqHbLg + rBIbzTkmHOGdjgTHhOqfvGVEI5zjBE5U/zX9gZNcCPzmW7E+5LZGAsMCK8n0pK/zr70L + BLVBEPge9YpgA3v8Vi/MqLbDuvQtSkF5zhj2qsIK851jc3rim8GCjuLOuOIZpMhHrL7+ + XR7n4AhoLQUoHkdcNRoUGsk9UB7RVEyAGlkCPPFYu4fy0lgZAdGX57gdnnxtWt1S3EZR + BYfg== +Received: by 10.180.103.35 with SMTP id ft3mr3075901wib.0.1330779820580; + Sat, 03 Mar 2012 05:03:40 -0800 (PST) +Received: from localhost (94-192-233-223.zone6.bethere.co.uk. + [94.192.233.223]) by mx.google.com with ESMTPS id + fb2sm9380837wid.3.2012.03.03.05.03.39 (version=TLSv1/SSLv3 cipher=OTHER); + Sat, 03 Mar 2012 05:03:39 -0800 (PST) +From: Mark Walters +To: notmuch@notmuchmail.org +Subject: [PATCH 0/5] Move to --with-excluded approach to excludes +Date: Sat, 3 Mar 2012 13:05:13 +0000 +Message-Id: <1330779918-28024-1-git-send-email-markwalters1009@gmail.com> +X-Mailer: git-send-email 1.7.2.3 +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: Sat, 03 Mar 2012 13:03:45 -0000 + +This series implements the proposal in id:"87y5riuz7v.fsf@qmul.ac.uk" +to move to a consistent --with-excluded approach rather than the +previous --no-exclude approach. See the message there and its +descendants for discussion. + +The main user side change is that notmuch-search no longer defaults to +showing all the excluded threads with [0/n] but will do so if the user +says they want all the messages (i.e., by specifying --with-excluded). + +However, it makes everything consistent throughout the commandline and +lib interfaces. In all cases a "message" type search only returns the +non-excluded matches (unless --with-excluded is specified) and a +"thread" type search returns all messages (including excluded ones) in +threads that match in a non-excluded message. + +The patch series is bigger than I would like but it is relatively +simple: the slightly tricky logic of the original series is +untouched. This series just changes the names and defaults fed to the +existing logic. + +The only slightly complicated part is the notmuch-show.c patch as it +has to decide quite what to do in lots of cases. See +id:"87d38t26wp.fsf@qmul.ac.uk" for reasons for the precise choices +made. + +Best wishes + +Mark + +Mark Walters (5): + lib: rename (and negate) set_omit_excluded set_with_excluded + cli: move count to the new --with-excluded naming scheme. + cli: move search to the new --with-excluded naming scheme. + cli: move show to the new --with-excluded naming scheme. + emacs: make show set --with-excluded + + emacs/notmuch-show.el | 6 ++++-- + lib/notmuch.h | 12 +++++++----- + lib/query.cc | 10 +++++----- + man/man1/notmuch-count.1 | 4 ++-- + man/man1/notmuch-search.1 | 6 ++++-- + man/man1/notmuch-show.1 | 5 +++-- + notmuch-client.h | 1 + + notmuch-count.c | 11 ++++++----- + notmuch-search.c | 20 +++++++++++--------- + notmuch-show.c | 38 +++++++++++++++++++++----------------- + test/count | 4 ++-- + test/search | 9 ++++----- + 12 files changed, 70 insertions(+), 56 deletions(-) + +-- +1.7.2.3 + -- 2.26.2