Re: [PATCH 3/5] cli/count: add --output=modifications

Subject: Re: [PATCH 3/5] cli/count: add --output=modifications

Date: Tue, 11 Aug 2015 23:13:42 +0300

To: David Bremner, notmuch@notmuchmail.org

Cc:

From: Tomi Ollila


On Tue, Aug 11 2015, David Bremner <david@tethera.net> wrote:

> Tomi Ollila <tomi.ollila@iki.fi> writes:
>
>> Currently, `notmuch count` outputs lines that contain just one integer;
>> this changes this by introducing output with uuid ([0-9a-f-]) and integer
>> delimited by tab character.
>>
>> To put it lightly, this looks "inconsistent" and don't please my aesthetic
>> eye.
>>
>> One option (being it worse or better) could be that by default only
>> lastmod value is printed and with separate option it is prefixed with
>> database UUID (in every --output option).
>
> Can you think of any use case for the uuid with the other count outputs?
> It feels pretty artificial to me.

I don't... I just thought something consistent to be used w/ notmuch count...

> Another option is to make a "notmuch metadata" command. I'm not really
> sure about the syntax, but perhaps a uuid option makes more sense
> there, so e.g.
>
>        notmuch metadata --with-uuid lastmod

or notmuch metadata key [key [key]], then (currently) we could have:

$ notmuch metadata uuid
$ notmuch metadata lastmod
$ notmuch metadata uuid lastmod
$ notmuch metadata lastmod uuid 

Now we can bikeshed whether this is good idea -- and what to do (and when)
if unknown key is used in request...


Tomi

> I'm pretty convinced that we need report uuid and lastmod together (at
> least optionally). I'm less sure we need a full get/set interface for
> metadata, since people with that use case could use xapian-metadata.
>

Thread: