unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: David Bremner <david@tethera.net>
To: Jesse Rosenthal <jrosenthal@jhu.edu>,
	Jameson Graef Rollins <jrollins@finestructure.net>,
	Notmuch Mail <notmuch@notmuchmail.org>
Subject: Re: tag sharing
Date: Thu, 06 Oct 2011 21:10:50 -0300	[thread overview]
Message-ID: <8762k1u0dx.fsf@zancas.localnet> (raw)
In-Reply-To: <m1obxt3lcv.fsf@watt.hwcampus.jhu.edu>

On Thu, 06 Oct 2011 16:40:00 -0400, Jesse Rosenthal <jrosenthal@jhu.edu> wrote:
> On Thu, 06 Oct 2011 17:23:21 -0300, David Bremner <david@tethera.net> wrote:
> > What doesn't work is searches for the whole namespace "notmuch search
> > tag:bremner.*" will return nothing, even though "notmuch search
> > tag:bremner.to-fix" does.
> 
> A simple shell way to do this would be
> 
>     notmuch search-tags | grep "^bremner\." | xargs -I {} notmuch search tag:{}
> 

Ah thanks, that is not so bad. It turns out to be literally a one line
change to add a query argument for notmuch-dump, _except_ that notmuch
dump already uses the first command line argument as an output file
name. I think I will start a seperate thread about that. If you want to
test, this works OK, except the output is put in a file named after the
query ;).

diff --git a/notmuch-dump.c b/notmuch-dump.c
index 7e7bc17..341207a 100644
--- a/notmuch-dump.c
+++ b/notmuch-dump.c
@@ -40,7 +40,7 @@ notmuch_dump_command (unused (void *ctx), int argc, char *argv[])
     if (notmuch == NULL)
 	return 1;
 
-    query = notmuch_query_create (notmuch, "");
+    query = notmuch_query_create (notmuch, argc > 0 ? argv[0] : "");
     if (query == NULL) {
 	fprintf (stderr, "Out of memory\n");
 	return 1;

  reply	other threads:[~2011-10-07  0:11 UTC|newest]

Thread overview: 62+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-28 21:51 release-candidate/0.6 redux Jameson Graef Rollins
2011-05-28 21:51 ` [PATCH 01/25] fix check for libdir in ldconfig paths Jameson Graef Rollins
2011-05-28 21:51   ` [PATCH 02/25] add note about updating the debian symbols file to the RELEASE file Jameson Graef Rollins
2011-05-28 21:51     ` [PATCH 03/25] test: modify search-output test to use the new test_expect_equal_file function Jameson Graef Rollins
2011-05-28 21:51       ` [PATCH 04/25] test: move "Search for non-existent message prints nothing" to search-output, and add similar test for format=json Jameson Graef Rollins
2011-05-28 21:51         ` [PATCH 05/25] fix trailing newlines in notmuch search Jameson Graef Rollins
2011-05-28 21:51           ` [PATCH 06/25] test: move utf-8 subject search test from json to search test script Jameson Graef Rollins
2011-05-28 21:51             ` [PATCH 07/25] test: remove json test for search null result, since it's being more properly tested in search-output Jameson Graef Rollins
2011-05-28 21:51               ` [PATCH 08/25] create and set temporary home directory Jameson Graef Rollins
2011-05-28 21:51                 ` [PATCH 09/25] emacs: Define several faces for the crypto-status button Jameson Graef Rollins
2011-05-28 21:51                   ` [PATCH 10/25] Sanitize "Subject:" and "Author:" fields to not contain control characters in notmuch-search Jameson Graef Rollins
2011-05-28 21:51                     ` [PATCH 11/25] test: add test for sanitized notmuch-search output Jameson Graef Rollins
2011-05-28 21:51                       ` [PATCH 12/25] test: cleanup search-output test names (no functional change) Jameson Graef Rollins
2011-05-28 21:51                         ` [PATCH 13/25] emacs: Use "message-cited-text" instead of "message-cited-text-face" Jameson Graef Rollins
2011-05-28 21:51                           ` [PATCH 14/25] Fix old style notmuch-fcc-dirs configuration check Jameson Graef Rollins
2011-05-28 21:51                             ` [PATCH 15/25] Use message-field-value instead of message-fetch-field in FCC header setup Jameson Graef Rollins
2011-05-28 21:51                               ` [PATCH 16/25] lib/message-file: plug three memleaks Jameson Graef Rollins
2011-05-28 21:51                                 ` [PATCH 17/25] avoid segfault when calling sanitize_string() on NULL Jameson Graef Rollins
2011-05-28 21:51                                   ` [PATCH 18/25] Fix search output sanitization test Jameson Graef Rollins
2011-05-28 21:51                                     ` [PATCH 19/25] emacs: fix notmuch-show-part-button to not include newline Jameson Graef Rollins
2011-05-28 21:51                                       ` [PATCH 20/25] emacs: Don't always prompt for the "From" address when replying Jameson Graef Rollins
2011-05-28 21:51                                         ` [PATCH 21/25] emacs: Cleaner interface when prompting for sender address Jameson Graef Rollins
2011-05-28 21:51                                           ` [PATCH 22/25] test: fix test_expect_equal_file test to copy instead of mv test files Jameson Graef Rollins
2011-05-28 21:51                                             ` [PATCH 23/25] test: update emacs test to use test_expect_equal_file Jameson Graef Rollins
2011-05-28 21:51                                               ` [PATCH 24/25] test: modify multipart " Jameson Graef Rollins
2011-05-28 21:52                                                 ` [PATCH 25/25] Fix stdout stream grabbing in format_part_content_text Jameson Graef Rollins
2011-06-03 19:56                                                   ` Carl Worth
2011-06-03 21:26                                                     ` Jameson Graef Rollins
2011-06-03 22:38                                                       ` Carl Worth
2011-06-03 22:57                                                         ` Jameson Graef Rollins
2011-06-03 21:39                                                     ` Jameson Graef Rollins
2011-06-03 19:24                                   ` [PATCH 17/25] avoid segfault when calling sanitize_string() on NULL Carl Worth
2011-06-02  5:10                             ` [PATCH 14/25] Fix old style notmuch-fcc-dirs configuration check Carl Worth
2011-06-02  6:49                               ` Dmitry Kurochkin
2011-06-03 20:05                                 ` Carl Worth
2011-06-03 20:22                                   ` Dmitry Kurochkin
2011-06-03 21:03                                     ` Carl Worth
2011-06-23 22:22                                     ` Carl Worth
2011-06-23 22:58                                       ` Dmitry Kurochkin
2011-06-23 23:24                                         ` Carl Worth
2011-06-01 23:41               ` [PATCH 07/25] test: remove json test for search null result, since it's being more properly tested in search-output Carl Worth
2011-06-01 23:22   ` [PATCH 01/25] fix check for libdir in ldconfig paths Carl Worth
2011-06-01 23:27     ` Jameson Graef Rollins
2011-05-28 21:58 ` release-candidate/0.6 redux Jameson Graef Rollins
2011-05-29  2:49   ` Austin Clements
2011-05-31 18:43   ` Jameson Graef Rollins
2011-06-04  1:27     ` Carl Worth
2011-06-06  0:35       ` Jameson Graef Rollins
2011-06-06 12:17         ` Carl Worth
2011-06-06 16:28           ` tag sharing [was: Re: release-candidate/0.6 redux] Jameson Graef Rollins
2011-06-06 17:20             ` Jesse Rosenthal
2011-06-08 17:46               ` Jameson Graef Rollins
2011-06-08 19:18                 ` Jesse Rosenthal
2011-10-06 12:56                 ` tag sharing David Bremner
2011-10-06 13:21                   ` Jesse Rosenthal
2011-10-06 14:18                     ` David Bremner
2011-10-06 19:49                       ` Jesse Rosenthal
2011-10-06 20:23                         ` David Bremner
2011-10-06 20:40                           ` Jesse Rosenthal
2011-10-07  0:10                             ` David Bremner [this message]
2011-10-07 11:36                       ` Jesse Rosenthal
2011-10-07 12:01                         ` Jesse Rosenthal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=8762k1u0dx.fsf@zancas.localnet \
    --to=david@tethera.net \
    --cc=jrollins@finestructure.net \
    --cc=jrosenthal@jhu.edu \
    --cc=notmuch@notmuchmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).