Re: Database location bug when database does not already exist

2022-09-03 Thread Sean Whitton
Hello, On Sat 03 Sep 2022 at 08:34AM -03, David Bremner wrote: > Sean Whitton writes: > >> Hello, >> >> In the following situation: >> >> - only notmuch config is ~/.notmuch-config >> - database.mail_root is set >> - database.path is not set >> - notmuch database does not yet exist >> >> then

[PATCH 2/3] lib: parse index.as_text

2022-09-03 Thread David Bremner
We pre-parse into a list of compiled regular expressions to avoid calling regexc on the hot (indexing) path. As explained in the code comment, this cannot be done lazily with reasonable error reporting, at least not without touching a lot of the code in index.cc. --- lib/database-private.h | 4

[PATCH 1/3] lib: add config key INDEX_AS_TEXT

2022-09-03 Thread David Bremner
Higher level processing as a list of regular expressions and documentation will follow. --- lib/config.cc| 3 +++ lib/notmuch.h| 1 + test/T030-config.sh | 1 + test/T055-path-config.sh | 1 + test/T590-libconfig.sh | 5 + 5 files changed, 11 insertions(+) diff

[PATCH 3/3] lib: index attachements with mime types matching index.as_text

2022-09-03 Thread David Bremner
Instead of skipping indexing all attachments, we check of a (user configured) mime type that is indexable as text. --- doc/man1/notmuch-config.rst | 7 +++ lib/database.cc | 12 lib/index.cc| 25 ++--- lib/notmuch-private.h |

index user selected MIME types of attachments

2022-09-03 Thread David Bremner
This series obsoletes the WIP patch [1]. Most of the work is in making it configurable. [1]: id:20220820185007.289543-4-da...@tethera.net ___ notmuch mailing list -- notmuch@notmuchmail.org To unsubscribe send an email to notmuch-le...@notmuchmail.org

Re: [PATCH 1/3] test: rename indexing corpus

2022-09-03 Thread David Bremner
David Bremner writes: > The corpus is not really suitable for general indexing test since the > sole message is ignored (and will most likely continue to be ignored) > by notmuch-new. applied the first two patches (test changes) to master ___ notmuch

Re: Feature request: search for last N modified mails

2022-09-03 Thread David Bremner
Ico writes: > My normal mail workflow is to keep todo's in my inbox; these can be a few days > or weeks old if I'm lazy. Every now and then I find myself accidentally > removing things from the inbox, and I have a very hard time finding things > back. As discussed on #notmuch IRC today: I'd like

Re: [PATCH 1/3] lib/sexp: provide relative lastmod queries

2022-09-03 Thread David Bremner
David Bremner writes: > Test the relatively trivial logic changes for the sexp query parser > first before refactoring that logic to share with the infix query > parser. series applied to master. d ___ notmuch mailing list -- notmuch@notmuchmail.org

Re: Database location bug when database does not already exist

2022-09-03 Thread David Bremner
Sean Whitton writes: > Hello, > > In the following situation: > > - only notmuch config is ~/.notmuch-config > - database.mail_root is set > - database.path is not set > - notmuch database does not yet exist > > then notmuch wants to create its db under mail_root/.notmuch, contrary > to

Re: [PATCH 2/6] test: add test for creating database in various configurations.

2022-09-03 Thread David Bremner
David Bremner writes: > The existing database creation (via add_email_corpus) was always done > in the traditional configuration. The use of xapian-metadata is just > to portably ensure that there is a database created where we expect > there to be. remainder of the series applied to master. d

Re: [PATCH] emacs: new notmuch-tree-process-exit-functions

2022-09-03 Thread David Bremner
jao writes: > Hook run when the tree insertion process finishes its job. > applied to master ___ notmuch mailing list -- notmuch@notmuchmail.org To unsubscribe send an email to notmuch-le...@notmuchmail.org

Re: [PATCH] emacs/show: use read-shell-command instead of read-string

2022-09-03 Thread David Bremner
Antoine Beaupré writes: > This enables auto-completion of commands, something which plain > read-string does not do. It's otherwise a drop-in > replacement. According to `C-h f`, read-shell-command was introduced > in Emacs 23.1 or earlier. Applied to master. d