aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* Makefile: Remove unused variable emacs_startdirCarl Worth2009-11-20
| | | | | | This was added in a prelimnary version of a previous commit that would automatically load notmuch.el for anyone running emacs. It's not used at all in the current Makefile.
* Avoid access of a Xapian iterator's object when there's nothing there.Carl Worth2009-11-20
| | | | | | | This eliminates a crash when a message (either corrupted or a non-mail file that wasn't properly detected as not being mail) has no In-Reply-To header, (and so few terms that trying to skip to the prefix of the In-Reply-To terms actually brings us to the end of the termlist).
* Revert inadvertently committed code.Carl Worth2009-11-20
| | | | | | | | | This was accidentally included with commit: ddac17343a30976cae82c9f57419c063e1585cc0 (It was a dirty chunk in my directory that I accidentally amended into the submitted patch.)
* notmuch build: add a RPM spec fileJeffrey C. Ollie2009-11-20
| | | | | | Add a spec file for building RPM packages. Signed-off-by: Jeffrey C. Ollie <jeff@ocjtech.us>
* Add a .desktop file entry.Jeffrey C. Ollie2009-11-20
| | | | | | | This will add an entry in your window manager's menus that will create up a new emacs process and start notmuch. Signed-off-by: Jeffrey C. Ollie <jeff@ocjtech.us>
* Improve installation of emacs mode.Jeffrey C. Ollie2009-11-20
| | | | | | | | | | | | | | | | | | 1) Add a separate targets to build and install emacs mode. 2) Don't hardcode the installation directory, instead use emacs' pkg-config module. 3) Install a byte compiled version of the emacs mode. 4) Install the emacs mode in emacs' site-lisp directory. Put "(require 'notmuch)" in your .emacs to load it automatically. 5) Ignore byte-compiled emacs files. Signed-off-by: Jeffrey C. Ollie <jeff@ocjtech.us> Reviewed-by: Ingmar Vanhassel <ingmar@exherbo.org> Reviewed-by: Keith Packard <keithp@keithp.com>
* Have git ignore tags & cscope filesRolland Santimano2009-11-20
|
* Put $(LDFLAGS) after the list of object files.Peter Wang2009-11-19
| | | | | | Some linkers on some systems are particularly picky about the order of arguments in order to properly linkt. So this fixes failures on some systems.
* notmuch: Add search mode hookAneesh Kumar K.V2009-11-19
| | | | | | | | This patch add notmuch-search-hook that gets run when we after displaying search results Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> Cc:Keith Packard <keithp@keithp.com>
* Makefile: Create elisp install directory explicitlyIngmar Vanhassel2009-11-19
| | | | | | | When doing a DESTDIR install, this directory likely won't exist, and installing notmuch.el will fail. See 0d4b5292
* bash-completion: Complete options for notmuch searchIngmar Vanhassel2009-11-19
|
* bash-completion: Localize variables, use more consistent variable namesIngmar Vanhassel2009-11-19
|
* bash-completion: Whitespace fixIngmar Vanhassel2009-11-19
| | | | Signed-off-by: Ingmar Vanhassel <ingmar@exherbo.org>
* bash-completion: Bash has & should use [[ == ]]Ingmar Vanhassel2009-11-19
| | | | Signed-off-by: Ingmar Vanhassel <ingmar@exherbo.org>
* Allow lone "not" search operatorsAdrian Perez2009-11-19
| | | | | | | | | | | | | | | | | | As suggested by Keith in FLAG_PURE_NOT allows for expressions like: notmuch search NOT tag:inbox Note that this way a search like: notmuch search foobar NOT tag:inbox should not be written instead: notmuch search foobar AND NOT tag:inbox In my opinion, the latter feels more natural and is somewhat more explicit. It gives a better clue of what the search is about instead of assuming that an implicit AND operator is there.
* .gitignore: Add common editor droppingsIngmar Vanhassel2009-11-19
|
* notmuch new: Restore printout of total files counted.Carl Worth2009-11-19
| | | | This was more fallout from the recent re-shuffling of this code.
* notmuch new: Fix countdown timer on first run.Carl Worth2009-11-19
| | | | | A recent shuffling of this code accidentally disabled the timer, (making the time spent counting the files totally useless).
* Makefile: Actually install the emacs mode.Carl Worth2009-11-19
| | | | Should have been doing this a long time ago.
* notmuch.el: Add a reply binding ('r') to search mode to reply to a whole thread.Carl Worth2009-11-19
| | | | | | This is basically right, (I get a message buffer with all the mails quoted), but somehow notmuch reply is reversing the messages. That's a nuisance.
* reply: Pointer mismatch.Chris Wilson2009-11-19
| | | | Apparently typeof (size_t) != unsigned int on my x86-64.
* Makefile: evaluate pkg-config onceChris Wilson2009-11-19
| | | | | Currently the same `pkg-config ...` is executed for every target, so just store the results in a variable.
* Make reply/show/tag all require at least one search termKeith Packard2009-11-18
| | | | | | | | In particular, notmuch tag -inbox "" tended to take a long time to run, happened if you hit 'a' on a blank line in the search view and probably didn't have the desired effect. Signed-off-by: Keith Packard <keithp@keithp.com>
* Have git ignore etags fileKeith Packard2009-11-18
|
* Filter out carriage-returns in show and reply output.Keith Packard2009-11-18
| | | | | | Thanks, windows mail clients. Signed-off-by: Keith Packard <keithp@keithp.com>
* We use the message mail system for new mail, let emacs know.Keith Packard2009-11-18
| | | | | | | This makes things like the goto-address system bring up the right message composition window. Signed-off-by: Keith Packard <keithp@keithp.com>
* Create a default notmuch-show-hook that highlights URLs and uses word-wrapKeith Packard2009-11-18
| | | | | | | | | I created the notmuch-show-hook precisely so I could add these two options, but I suspect most people will want them, so I just made them the default. If you don't want them, you can use remove-hook to get rid of this. Signed-off-by: Keith Packard <keithp@keithp.com>
* Set truncate-lines variable for search buffers.Keith Packard2009-11-18
| | | | | | This keeps them from wrapping. Signed-off-by: Keith Packard <keithp@keithp.com>
* Add notmuch-show-hook to allow customization of show windowsKeith Packard2009-11-18
| | | | | | | | | I wanted to enable got-address-mode and visual-line-mode in my show windows to make messages easier to read and URLs easier to follow. This hook allows the user to run arbitrary code each time a message is shown. Signed-off-by: Keith Packard <keithp@keithp.com>
* count_files: sort directory in inode order before stattingStewart Smith2009-11-18
| | | | | | Carl says: This has similar performance benefits as the previous patch, and I fixed similar style issues here as well, (including missing more of a commit message than the one-line summary).
* Minor style fixups for the previous fix.Carl Worth2009-11-18
| | | | | Use consistent whitespace, a slightly less abbreviated identifier, and avoid a C99 declaration after statement.
* Read mail directory in inode number orderStewart Smith2009-11-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This gives a rather decent reduction in number of seeks required when reading a Maildir that isn't in pagecache. Most filesystems give some locality on disk based on inode numbers. In ext[234] this is the inode tables, in XFS groups of sequential inode numbers are together on disk and the most significant bits indicate allocation group (i.e inode 1,000,000 is always after inode 1,000). With this patch, we read in the whole directory, sort by inode number before stat()ing the contents. Ideally, directory is sequential and then we make one scan through the file system stat()ing. Since the universe is not ideal, we'll probably seek during reading the directory and a fair bit while reading the inodes themselves. However... with readahead, and stat()ing in inode order, we should be in the best place possible to hit the cache. In a (not very good) benchmark of "how long does it take to find the first 15,000 messages in my Maildir after 'echo 3 > /proc/sys/vm/drop_caches'", this patch consistently cut at least 8 seconds off the scan time. Without patch: 50 seconds With patch: 38-42 seconds. (I did this in a previous maildir reading project and saw large improvements too)
* Make '?" bring up a list of bindings.Carl Worth2009-11-18
| | | | | Just using describe-mode for now, (though something more specialized would be better).
* Fix linking with gcc to use g++ to link in C++ libs.Stewart Smith2009-11-18
| | | | | | | | Previously, Ubuntu 9.10, gcc 4.4.1 was getting: /usr/bin/ld: lib/notmuch.a(database.o): in function global constructors keyed to BOOLEAN_PREFIX_INTERNAL:database.cc(.text+0x3a): error: undefined reference to 'std::ios_base::Init::Init()'
* notmuch main(): Remove stale comment.Carl Worth2009-11-18
| | | | The code this comment was referring to has since been deleted.
* notmuch help: Print to stdout, not to stderr.Lars Kellogg-Stedman2009-11-18
| | | | | | Let usage() take a FILE * argument so that you can output to stderr in response to usage errors, and stdout in response to an explicit request.
* notmuch search: Avoid infinite stream of exceptions from "notmuch search"Carl Worth2009-11-18
| | | | | | That is, give a nice error message and exit if no search terms are provided. Thanks to Priit Laes <plaes@plaes.org> for reporting the error and providing an early version of the fix.
* README: Mention the actual mailing list address now that it exists.Carl Worth2009-11-18
| | | | Much better than telling people to mail me individually.
* TypsosIngmar Vanhassel2009-11-18
|
* Older versions of install do not support -C.Jan Janak2009-11-18
| | | | | | | | Do not use -C cmdline option of install, older versions, commonly found in distributions like Debian, do not seem to support it. Running make install on such systems (tested on Debian Lenny) fails. Signed-off-by: Jan Janak <jan@ryngle.com>
* linke_message: Avoid segfault when In-Reply-to header is empty.Carl Worth2009-11-18
| | | | | | | | | | | | | This was recently introduced in commit: 64c03ae97f2f5294c60ef25d7f41849864e6ebd3 which was adding extra checks to avoid adding a self-referencing message. How many times am I going to fix a dumb regression like this and say "we really need a test suite" before I actually sit down and write the test suite?
* notmuch-completion.bash: Update for new commands and help.Carl Worth2009-11-18
| | | | Would be nice to add the options for "notmuch search" too.
* notmuch help: Update documentation (following recent text from notmuch.1)Carl Worth2009-11-17
| | | | | | | We take the recently created text from the notmuch manual page and update the "notmuch help" command to use similar text. In particular, we add a new "notmuch help search-terms" for documenting the search syntax that is common to several commands.
* notmuch.1: Fix a couple of typos.Carl Worth2009-11-17
| | | | | Little things I noticed while using this text as reference for the "notmuch help" documentation.
* man.1: A big update of the notmuch manual page.Carl Worth2009-11-17
| | | | | | | | | | | | I set out merely to add documentation for the recently-added options for "notmuch search" (--first, --max-threads, and --sort), but ended up revamping a lot. A significant change is a new SEARCH SYNTAX section separate from "notmuch search" that is referred to in the documentation of search, show, reply, and tag. Also many sections were updated to reflect recent changes, (such as the dropping of the NOTMUCH_BASE environment variable, the addition of the .notmuch-config file, etc.)
* Makefile: Fix missing dependency for notmuch.1 manual page.Carl Worth2009-11-17
| | | | | | The Makefile was failing to regnerate the notmuch.1.gz file when notmuch.1 was updated, (so stale documentation could potentially be installed).
* notmuch search: Change default search order to be newest messages first.Carl Worth2009-11-17
| | | | | | | | | | | | | | | | | This is what most people want for a _search_ command. It's often different for actually reading mail in an inbox, (where it makes more sense to have results displayed in chronological order), but in such a case, ther user is likely using an interface that can simply pass the --sort=oldest-first option to "notmuch search". Here we're also change the sort enum from NOTMUCH_SORT_DATE and NOTMUCH_SORT_DATE_REVERSE to NOTMUCH_SORT_OLDEST_FIRST and NOTMUCH_SORT_NEWEST_FIRST. Similarly we replace the --reverse option to "notmuch search" with two options: --sort=oldest-first and --sort=newest-first. Finally, these changes are all tracked in the emacs interface, (which has no change in its behavior).
* notmuch search: Return first 100 results as quickly as possible.Carl Worth2009-11-17
| | | | | | | | | This is one of those cases where total time is not the metric of interest. We increase the total time of the search, (by doing some redundant work for the initial threads). But more significantly, we give the user *some* results nearly instantaneously, (so that the user might see the result of interest without ever even waiting for the complete results to come in).
* Add some const correctness to talloc 'ctx' parameter.Carl Worth2009-11-17
| | | | The tentacles of const just keep reaching out.
* database: Make _parse_message_id static once again.Carl Worth2009-11-17
| | | | | | | We had exposed this to the internal implementation for a short time, (only while we had the silly code fetching In-Reply-To values from message files instead of from the database). Make this private again as it should be.