unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: Carl Worth <cworth@cworth.org>
To: Jan Janak <jan@ryngle.com>
Cc: notmuch@notmuchmail.org
Subject: Re: [PATCH 2/2] notmuch list: A new command to produce various lists.
Date: Sun, 22 Nov 2009 00:07:57 +0100	[thread overview]
Message-ID: <87my2f329e.fsf@yoom.home.cworth.org> (raw)
In-Reply-To: <f35dbb950911211307t1cd8e039xca754828c75b26f6@mail.gmail.com>

On Sat, 21 Nov 2009 22:07:14 +0100, Jan Janak <jan@ryngle.com> wrote:
> My patch no longer works and I have been thinking about updating it to
> current HEAD. But before I do that, I wanted to check with you to see
> if you would prefer to use a different name for the command, here are
> some options:
> 
>   1) notmuch tags
>   2) notmuch list tags
>   3) notmuch list-tag
> 
> Any opinions?
> 
> I also plan to add support for search-terms later so that we can
> produce tag lists for a set of messages, as you mentioned in one of
> your previous emails.

I don't think "list" would make sense unless it didn't support search
terms at all.

So I proposed my "search-messages" command earlier as well.

It's clear that there are lots of different things that we're going to
want to search for in the database and then lots of way's that we're
going to want to present the resulting data.

I would rather like there to be some correlation between commands with
shorter names being more likely to be the kind of thing that a user
would use directly from the command line. And longer names can be used
for things that are more for interfaces to use, and for people to use in
writing scripts.

So how about "search-tags" and "search-messages" ?

Any better ideas?

Another option would be to just call this "notmuch search" and have an
option to control what is output:

       notmuch search	# for threads, as currently
       notmuch search --output=tags
       notmuch search --output=messages

Actually, I kind of like that. For one thing, it makes it easy to
eliminate the redundancy I made with the option-parsing in both
notmuch-search.c and notmuch-search-message.c.

> A quick description for those who joined later: This command produces
> a list of all tags defined in the database. The emacs interface uses
> it to implement tag name completion.

And I can't wait to have tag completion in the interface. This will be
nice.

One thing we'll still have to think about is how to remove the "virtual
tags" from the completion list, (once we have virtual tags in the
configuration file---that is, tags applied automatically based on search
specifications).

The place we'd want to remove these from the completion list is when
adding/removing a tag---it should be illegal to add/remove virtual tags
since they will be maintained by the system according to the search
specifications.

Of course, when searching/filtering by tag, the completion list should
include all tags, whether manual or virtual.

So, what we're going to need for that is something like "notmuch config"
that allows the interface to query the configuration.

But that's all down the road. Let's get that tag completion working!

-Carl

  reply	other threads:[~2009-11-21 23:08 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-19 11:34 [PATCH 1/2] notmuch: Support for notmuch_database_get_tags Jan Janak
2009-11-19 11:34 ` [PATCH 2/2] notmuch list: A new command to produce various lists Jan Janak
2009-11-19 11:52   ` Jan Janak
2009-11-19 14:41     ` Carl Worth
2009-11-19 15:40       ` Jan Janak
2009-11-19 17:59       ` Bdale Garbee
2009-11-20  0:26         ` Carl Worth
2009-11-21 21:07       ` Jan Janak
2009-11-21 23:07         ` Carl Worth [this message]
2009-11-21 23:21           ` Jed Brown
2009-11-22  3:53             ` Carl Worth
2009-11-22  3:45           ` Bart Trojanowski

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=87my2f329e.fsf@yoom.home.cworth.org \
    --to=cworth@cworth.org \
    --cc=jan@ryngle.com \
    --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).