notmuch/emacs
Michal Sojka 89f78d38c1 Emacs: Add address completion mechanism implemented in elisp
Currently, notmuch has an address completion mechanism that requires
external command to provide completion candidates. This commit adds a
completion mechanism inspired by https://github.com/tjim/nevermore,
which is implemented in Emacs lisp only.

The preexisting address completion mechanism, activated by pressing
TAB on To/Cc lines, is extended to use the new mechanism when
notmuch-address-command to 'internal, which is the new default.

The core of the new mechanism is the function notmuch-address-harvest,
which collects the completion candidates from the notmuch database and
stores them in notmuch-address-completions variable. The address
harvesting can run either synchronously (same as with the previous
mechanism) or asynchronously. When the user presses TAB for the first
time, synchronous harvesting limited to user entered text is performed.
If the entered text is reasonably long, this operation is relatively
fast. Then, asynchronous harvesting over the full database is triggered.
This operation may take long time (minutes on rotating disk). After it
finishes, no harvesting is normally performed again and subsequent
completion requests use the harvested data cached in memory. Completion
cache is updated after 24 hours.

Note that this commit restores (different) completion functionality for
users when the user used external command named "notmuch-addresses",
i.e. the old default.  The result will be that the user will use
the new mechanism instead of this command. I believe that many users may
not even recognize this because the new mechanism works the same as
http://commonmeasure.org/~jkr/git/notmuch_addresses.git and perhaps also
as other commands suggested at
http://notmuchmail.org/emacstips/#address_completion.

[This feature was significantly improved by David Bremner and Mark Walters]
2015-10-27 08:01:05 -03:00
..
.gitignore emacs: add notmuch-version.el.tmpl and create notmuch-version.el from it 2014-04-10 23:25:36 -03:00
coolj.el emacs: Add more functions to clean up text/plain parts 2010-04-26 10:05:46 -07:00
make-deps.el emacs: Compute build dependencies to fix byte compile issues 2013-05-23 08:06:12 -03:00
Makefile fix sum moar typos [build scripts, Makefiles] 2011-06-23 15:44:59 -07:00
Makefile.local emacs: Introduce notmuch-jump: shortcut keys to saved searches 2014-08-05 08:07:27 -03:00
notmuch-address.el Emacs: Add address completion mechanism implemented in elisp 2015-10-27 08:01:05 -03:00
notmuch-crypto.el emacs: show: make buttons select window 2013-02-18 20:13:19 -04:00
notmuch-hello.el emacs: hello: bugfix: update docs for saved-searches 2015-10-22 07:43:54 -03:00
notmuch-jump.el emacs: allow saved searches to select tree-view 2015-10-21 09:13:55 -03:00
notmuch-lib.el Emacs: Add address completion mechanism implemented in elisp 2015-10-27 08:01:05 -03:00
notmuch-logo.png emacs: Add notmuch-hello.el, a friendly frontend to notmuch 2010-04-23 12:50:18 -07:00
notmuch-maildir-fcc.el emacs: make modifications to message Fcc vars buffer-local 2015-08-07 21:18:59 +02:00
notmuch-message.el emacs: replace (funcall 'foo ...) with (foo ...) 2013-06-02 11:37:22 -03:00
notmuch-mua.el emacs: replace use of notmuch-address-message-insinuate 2015-10-27 08:00:49 -03:00
notmuch-parser.el emacs: Streaming S-expression parser 2013-06-01 08:56:25 -03:00
notmuch-print.el emacs: Put notmuch-print-mechanism in custom group notmuch-show 2012-04-24 23:25:51 -03:00
notmuch-query.el emacs: dropped rest of now-unused JSON functionality 2013-07-20 09:13:48 -03:00
notmuch-show.el emacs: show: increase default max-text-part-size 2015-10-17 09:07:36 -03:00
notmuch-tag.el Fix documentation for notmuch--tag-hook functions 2015-06-30 21:37:25 +02:00
notmuch-tree.el emacs: tree: bind S to run current query in search mode 2015-10-21 09:14:07 -03:00
notmuch-version.el.tmpl emacs: add notmuch-version.el.tmpl and create notmuch-version.el from it 2014-04-10 23:25:36 -03:00
notmuch-wash.el emacs: Washing should use more `defcustom'. 2015-01-11 14:32:32 +01:00
notmuch.el emacs: wrap current search in parens when filtering 2015-09-07 09:27:09 -03:00