aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2010-04-24emacs: Don't display From header by default.Carl Worth
This header is redundant with the summary-line of each message which contains the same information.
2010-04-24emacs: Allow user to customize which headers are visible.Carl Worth
Continuing our tradition of making more and more of the notmuch functionality configurable fromt eh customize interface.
2010-04-24emacs: Change message headers (To, CC, From, and Date) to be visible by defaultCarl Worth
Users can still toggle these to be hidden by default, and can still toggle visibility of headers for a single message with the 'h' command.
2010-04-24emacs: Allow headers to be shown by default in show modeDavid Edmondson
Add `notmuch-show-headers-visible' which, when set `t', causes headers to be shown by default.
2010-04-23removed unused variablesDirk Hohndel
trivial compiler warning fix Signed-off-by: Dirk Hohndel <hohndel@infradead.org>
2010-04-23emacs: Add notmuch-address.el for address completion using notmuchDavid Edmondson
A tool `notmuch-addresses' is required to produce addresses which match a query string. An example of a suitable script can be found in the git repository at http://jkr.acm.jhu.edu/git/notmuch_addresses.git There are no doubt others.
2010-04-23emacs: Rename notmuch-show-toggle-all to notmuch-show-open-or-close-allCarl Worth
The function was named and documented incorrectly before, saying that it would "change the visibility of all messages". Instead it only opens the messages that are closed---it doesn't simultanesously close the messages that are open. (Granted, nobody would *want* that behavior I don't think, but the naming was confusing before.)
2010-04-23emacs/notmuch-show.el: Add `notmuch-show-toggle-all' bound to M-RETDavid Edmondson
`notmuch-show-toggle-all' changes the visibility all of the messages in the current thread. By default it makes all of the messages visible. With a prefix argument, it makes them all not visible.
2010-04-23fix expected test result to include Bcc linesDirk Hohndel
this test actually tests behavior that I consider as broken. The Bcc should be to the same address as used in the From line, otherwise we are creating a potential information leak as email that is related to one email account (say, work) is copied to a different account Signed-off-by: Dirk Hohndel <hohndel@infradead.org> Reviewed-by: Carl Worth <cworth@cworth.org> These tests don't actually pass yet, since the feature being tested has not been merged. But gettting these tests in first will let us more easily test that the feature actually works, (and will help us ensure we don't forget the feature before the next release).
2010-04-23add From guessing tests to test suiteDirk Hohndel
right now these are not trying to be overly fancy simply one test per strategy that we apply to figure out the best from address - including the fallback if there's nothing to go on Signed-off-by: Dirk Hohndel <hohndel@infradead.org>
2010-04-23emacs: Use single-quote not double-quote when constructing searchCarl Worth
Commit 44982ab33295009137e3740e644e793a08629762 added some extra quoting when constructing a search. A previous version of this patch had used single-quotation marks (') while this version used double-quotation marks ("). The intent of the extra quoting was to allow notmuch-command to be set to a script invoking ssh. What actually happens, however is that the extra quotation marks make it all the way into the query string seen by Xapian. And the double quotes trigger phrase searching, (which isn't desired here). The side-effect of that is that the emacs code would fallback to an unqalified query and display all threads with all messages open. We fix that side-effect now by using single-quote characters, but we'll want a better fix in the future to avoid Xapian seeing these characters at all I think.
2010-04-23emacs: Re-arrange message sending codeDavid Edmondson
Define a new `mail-user-agent' (`notmuch-user-agent') and use it by default. Re-arrange various routines that send mail to use this (compose, reply, forward). Insert a `User-Agent:' header by default. This is the real commit for this functionality this time. The previous attempt to merge this code: commit 57926bc7b0f784cbacb620fda0ee5157e2e0ff27 was botched (by Carl Worth, not David) to include only the Makefile change. So the build was broken until this commit that actually adds the new file.
2010-04-23test: Set fixed time zoneMichal Sojka
When the test suite is run in a different time zone that where Carl lives, some tests may fail depending on the time when the test suite is run. For example, just now I get: Search for all messages ("*"):... FAIL --- test-031.expected 2010-04-23 09:33:47.898634822 +0200 +++ test-031.output 2010-04-23 09:33:47.898634822 +0200 @@ -1,5 +1,5 @@ -thread:XXX 2001-01-05 [1/1] Notmuch Test Suite; Test message #6 (inbox unread) -thread:XXX 2001-01-05 [1/1] Notmuch Test Suite; Test message #14 (inbox unread) +thread:XXX 2001-01-06 [1/1] Notmuch Test Suite; Test message #6 (inbox unread) +thread:XXX 2001-01-06 [1/1] Notmuch Test Suite; Test message #14 (inbox unread) thread:XXX 2000-01-01 [1/1] Notmuch Test Suite; body search (inbox unread) thread:XXX 2000-01-01 [1/1] searchbyfrom; search by from (inbox unread) thread:XXX 2000-01-01 [1/1] Notmuch Test Suite; search by to (inbox unread) By setting a fixed time zone in the test script, these problems should be eliminated. Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
2010-04-23emacs: Push the cursor to point-max on `n' or `N' at the end of a threadDavid Edmondson
Sebastian pointed out that the pre-JSON UI would move the cursor to the end of the buffer if `n' or `N' is hit when on the last (unread) message. Mimic that behaviour in the new UI.
2010-04-23emacs: Re-arrange message sending codeDavid Edmondson
Define a new `mail-user-agent' (`notmuch-user-agent') and use it by default. Re-arrange various routines that send mail to use this (compose, reply, forward). Insert a `User-Agent:' header by default.
2010-04-23emacs: Fix some compilation warnings.Carl Worth
Fix missing argumen in declaration of notmuch-search function and add a definition of notmuch-search-continuation to avoid warning about assignment to a free variable.
2010-04-23emacs: Add notmuch-hello.el, a friendly frontend to notmuchDavid Edmondson
This is based on the prototype that Carl Worth described in the TODO file. It provides a search bar as well as support for recent searches, saved searches, and a list of all tags in the database (as well as the number of messages with each tag).
2010-04-23emacs: Remove `notmuch-search-authors-width' and fix the use of `notmuch-search-result-format' accordinglyDavid Edmondson
The width of the authors field in search output was previously specified in two places: - `notmuch-search-authors-width': the limit beyond which the authors names are truncated, - `notmuch-search-result-format': the layout of the search results. Changing the configuration of one of these may have required the user to know about and adapt the other accordingly. This led to confusion. Instead, remove `notmuch-search-authors-width' and perform truncation based on the relevant field in `notmuch-search-result-format'. Approved-By: Jameson Rollins <jrollins@finestructure.net>
2010-04-23Reintroduce patch to quote args in notmuch-show to facilitate remote useJesse Rosenthal
This reintroduces the patch committed in 9193455fa1, which was reverted during the upgrade to the JSON emacs UI.
2010-04-23notmuch setup: Prompt for tags to set on new messages.Carl Worth
Our "notmuch setup" command is only really helpful if it guides the user through all the possible options. So add this one.
2010-04-23config: Rename messages.new_tags to just new.tagsCarl Worth
I think one configuration group for each top-level command makes a lot of sense. And this makes the existing naming of set_new_tags and get_new_tags also very reasonable.
2010-04-23Clarify the documentation for the new_tags configuration option.Carl Worth
Specifically mentioning that it's a list separated by ';' and use "will" instead of "should".
2010-04-23notmuch setup: Fix new configuration-file groups to get commentsCarl Worth
Our intent has always been that when new configuration-file settings are created by notmuch, that they get created with comments telling the user how to use them. But this was only working before when the entire configuration file was created. We fix this so that when a new group is added, (such as the recently- added [messages] section) that it gets its documentation.
2010-04-23Sprinkle some const-correctness around new_tags.Carl Worth
To eliminate a compiler warning.
2010-04-23notmuch-config: make new message tags configurableBen Gamari
Add a new_tags option in the [messages] section of the configuration file to allow the user to specify which tags should be added to new messages by notmuch new.
2010-04-23python: Add UNSORTED as Query.SORT optionSebastian Spaeth
Keep up to date with the libnotmuch.so API. Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2010-04-23python: Delete unused filesSebastian Spaeth
No more .hg files needed in the git repo. No stock notmuch-test suite needed in a subdirectory. We have the real one in this repository Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2010-04-22test: Put the json tests into their own section.Carl Worth
Not that the sections actually mean anything yet, but it makes for clean output.
2010-04-22notmuch search: Fix timezone of timestamp in --format=json outputCarl Worth
This is one of those cases that I move love. Deleting code fixes a bug, (test suite now passes again).
2010-04-22First tests for JSON output and UTF-8 in mail body and subjectGregor Hoffleit
The test suite doesn't yet cover --format=json output nor UTF-8 in subject or body. This patch starts with test cases for 'search --format=json' and 'show --format=json'. Furthermore, it has test cases for a search for a UTF-8 string in a mail body for a UTF-8 string in a mail subject. Finally, it has a test case for --format=json with UTF-8 messages, demonstrating the fix in 1267697893-sup-4538@sam.mediasupervision.de. Reviewed-by: Carl Worth <cworth@cworth.org> Updated tests to current implementation of the test suite. These tests demonstrate a bug in the current implementation of "notmuch show --format=json", (timestamp output is changed depending on current timezone).
2010-04-22test: Make existing "notmuch show" test more resilientCarl Worth
If future updates to the test suite add more messages to the database before this "notmuch show" test, then the message-ID numbers in the expected output will all change. But we can at least compute the numbers so that this test will continue to pass.
2010-04-22json: Replace `date_unix' with `timestamp' in show outputDavid Edmondson
Search output was already using `timestamp' for a very similar field, so follow that.
2010-04-22emacs: Add customize treatment and rename refresh-script to notmuch-poll-scriptCarl Worth
With defcustom the user can easily find this variable (and its documentation) within "M-x customize-group" "notmuch" (though finding *that* is still tricky). The new name of notmuch-poll-script is also easier to remember, (for me at least).
2010-04-22emacs: Use consistent naming for the two new poll functions.Carl Worth
Emacs scoping rules strongly encourage us to have fully-namespaced function names. A prefix like "notmuch-search" is a pretty ugly namespace name, but it's what we have for now.
2010-04-22Add 'G' keybinding to folder and search view that triggers external pollDirk Hohndel
The new functions first check if an external poll script has been defined in the variable 'notmuch-external-refresh-script and if yes, runs that script before executing the existing refresh function (which is bound to '=') This can be used to have 'G' mimic the mutt behavior of polling an external mail server - or if the mail polling is already automatic, it can trigger the call to notmuch new and any necessary automatic tagging of new email. Signed-off-by: Dirk Hohndel <hohndel@infradead.org>
2010-04-22Revert "thread: Simplify code for assigning the subject."Carl Worth
This reverts commit 36e4459a328b8449b3e9d510be81a332a9b35aaa. With the two previous reverts, this fixes the recent message-sorting regression, so the test suite now passes again.
2010-04-22Revert "thread: Fix sort of search when constructing threads."Carl Worth
This reverts commit f43990ce134d838cdb2cdd5d0752a602e81cfdd9.
2010-04-22Revert "thread: Removed unsed sort argument from _thread_add_matched_message"Carl Worth
This reverts commit 7fb56f9dc5d8e66f717f5e48ecbfbc11c8190182.
2010-04-22test: Add a test to demonstrate message-sorting regression.Carl Worth
In the recent change to rename threads based on changing subject lines, I broke message ordering within "notmuch show" output. But our test suite didn't catch that regressions, because we didn't have any tests of "notmuch show". This adds one "notmuch show" test along with the thread-naming tests. It's not a whole suite of "notmuch show" testing, but it does catch this regression at least.
2010-04-22test: When a test fails, show diff only (save complete output to a file)Carl Worth
We're starting to get test output that's fairly long, so it's much kinder to just show a diff rather than displaying the complete expected and actual output. To allow the user to investigate things after the fact, we save the expected and actual output to files named test-${test_number}.expected and test-${test_number}.output .
2010-04-22test: Improve grammar in test-message subjects.Carl Worth
Before codifying these in any expected test output, I'd like them to at least resemble English.
2010-04-21Fix help message for "show"Jameson Rollins
Help message for "show" mistakenly refers to '--output' instead of '--format'.
2010-04-21Merge Sebastian Spaeth's python bindings into bindings/pythonCarl Worth
Sebastian offered to maintain these bindings within the notmuch repository and offered them in the following repository: git://github.com/spaetz/python-notmuch.git These are the bindings formerly known as "cnotmuch" and now known simply as "notmuch" from within python. The bindings are not yet integrated into the build system and packaging of the primary ntomuch repository.
2010-04-21Move everything down into a bindings/python directory.Carl Worth
In preparation for merging the python bindings into the notmuch repository.
2010-04-21thread: Removed unsed sort argument from _thread_add_matched_messageCarl Worth
The reworked solution for naming a thread based on the subject of oldest/newest matching message no longer needs this argument.
2010-04-21emacs: Move definition of notmuch-folders to earlier in the file.Carl Worth
To avoid a warning about a free variable from the emacs compiler.
2010-04-21emacs: Try to name search buffers using info in notmuch-foldersServilio Afre Puentes
As the user has already defined aliases for certain searches in notmuch-folders, search buffer names that use these aliases will be easier to identify.
2010-04-21notmuch-tag: don't sort messages before applying tag changesSebastian Spaeth
It's not neccessary to sort the results before we apply tags. Xapian contributor Olly Betts says that savings might be bigger with a cold file cache and (as unsorted implies really sorted by document id) a better cache locality when applying tags to messages. Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2010-04-21query.cc: allow to return query results unsortedSebastian Spaeth
Previously, we always sorted the returned results by some string value, (newest-to-oldest by default), however in some cases (as when applying tags to a search result) we are not interested in any special order. This introduces a NOTMUCH_SORT_UNSORTED value that does just that. It is not used at the moment anywhere in the code. Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2010-04-21notmuch: Abort if specified configuration file is not found.Carl Worth
When there is no configuration file at all, (and none specified), notmuch works correctly by assuming correct default values. But when the user specifies a configuration file (with the NOTMUCH_CONFIG environment variable) and that file doesn't exist, then notmuch should aboirt and let the user know about the problem.