[notmuch] [PATCH] Make notmuch-show 'X' (and 'x') commands remove inbox (and unread) tags

Carl Worth cworth at cworth.org
Sun Nov 22 19:03:12 PST 2009


On Sun, 22 Nov 2009 15:32:13 -0800, Keith Packard <keithp at keithp.com> wrote:
> That's a fine plan. It 'shouldn't' be too hard to implement either.

Noted in TODO for future reference.

> Btw, I'm thinking that it might be useful to create some 'global'
> notmuch keybindings and then create per-view bindings that also expose
> the global bindings. That way, things like 'm' to create a new mail
> would work consistently in each view. Note that this idea is
> inconsistent with the following though...

That's an excellent idea. And it's consistent with what I want 'a' to
do, (and I do think it's important to have these commands consistent
across the views). I think it's natural too. See below...

> I was trying to make the 'normal' action easier; for me, if I'm looking
> at a message, then the normal action is to mark it read and archived,
> but when I'm looking only at the subject line in the search window, the
> normal action is just to mark it archived (having not actually read the
> message).

I agree that "normal" should be easier too. So I just need to win you
over to my notion of "normal", (and teach you of the ways of the magic
space bar).

The most normal thing (for me) to do *when at the end of a thread* is
to mark it read, archive it, and then advance to the next message. And
that's exactly what space bar does.

If you're not at the end of a thread, then you can archive it, (that's
what 'a' is for), but it shouldn't be marked read, (because otherwise
that would be "cheating").[*]

And if you want to cheat willingly, (notmuch, please consider these
messages read even though you've never presented them to me), then
that should require an extra-explicit action. So that's the shift key.

[*] We should perhaps fix 'a' to remove the "unread" tag from any
messages that _are_ wholly visible in the current window. It's really
only when an entire thread fits this one, and I *did* read it, that I
end up reaching for the 'A' binding.

So does that make sense?

The question of whether you next want to see the next message, or you
would rather return to the search view, is a trickier one. I'd suggest
that there's no harm in seeing the next message after archiving the
current message, from which you can immediately return to the search
view with 'q' (or 'x' currently, but not with your patch). That does
mean that "archive and return to search" does require two keys instead
of one.

Hmm... if we fix 'a' to correctly remove "unread" from wholly
presented messages, then I wouldn't need the current 'A' keybinding at
all. That is, notmuch would be automatically managing "unread" tags in
a fairly consistent way, and we wouldn't be giving UI for the
"cheating", (which should be fine---I can't see a good reason for
cheating here).

If we did that, then we could make 'a' do archive-go-to-next-message
and 'A' do archive-return-to-search-view. What would you think about
that?

-Carl
Date: Mon, 23 Nov 2009 04:02:59 +0100
Message-ID: <871vjqgcyk.fsf at yoom.home.cworth.org>


More information about the notmuch mailing list