wangp / bower

A curses terminal client for the Notmuch email system
Other
119 stars 11 forks source link

Notmuch saved queries #40

Closed vivien closed 5 years ago

vivien commented 5 years ago

Hi there, first of all, thanks for the project, finally a notmuch frontend which feels mature and robust to me. I really like its simplicity and its convention-over-configuration feel as well, no tons of options to learn.

I was looking at the documentation and the search terms aliases which seem to have now an upstream alternative, i.e. the saved queries.

e.g. notmuch config set query.foo 'tag:foo AND bar' can be used with e.g. notmuch search query:foo and baz.

Shouldn't bower's search term aliases be deprecated in favor of the user configured query: search terms?

wangp commented 5 years ago

I'll add completion support for query:.

As for deprecating bower's search term aliases, perhaps we could make the ~NAME syntax equivalent to query:NAME. However, the ~ syntax would not be usable inside of saved queries themselves. It's not a big issue, but I'll continue to use search term aliases myself since the code is already there. If you need to use other notmuch clients as well, you might prefer saved queries instead.

vivien commented 5 years ago

Indeed ~NAME can look for a bower search term alias, or fallback to config get query.NAME so that retro-compatibility is maintained. Indeed I share notmuch saved queries between a status line, bower, and notmuch command line.

wangp commented 5 years ago

Yeah, that's probably acceptable. Please test the named-query branch.

vivien commented 5 years ago

Hi @wangp, I've first installed bower with the bower-mail AUR packages, which install Mercury as a shared library. Thus I don't have /usr/lib/mercury/lib/reg.gc/libmer_{std,rt}.a. How can I compile bower from source with a shared Mercury?

wangp commented 5 years ago

Disable this line in src/Mercury.options

MCFLAGS-bower += --mercury-linkage static
vivien commented 5 years ago

./bower works perfectly with query:<Tab> or ~<Tab>!

wangp commented 5 years ago

Merged to master, thanks for testing.