aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2010-04-14Fix bug in adding or removing tag by region.Jesse Rosenthal
There was a bug in notmuch-search-{add,remove}-tag-region, which would not behave correctly if the region went beyond the last message. Now, instead of simply iterating to the last line of the region, these functions will iterate to the minimum of the last line of the region and the last possible line, i.e. (- (line-number-at-pos (point-max)) 2) Tested-by: Carl Worth <cworth@cworth.org> Note that the old, buggy behavior included infinite loops of emacs lisp code, so the new behavior is significantly better than that.
2010-04-13TODO: Capture some recent ideas expressed on the mailing list.Carl Worth
There's a potential simplification of notmuch-reply.c and some emacs improvements that might require extending message-mode to a notmuch-message-mode.
2010-04-13Decode headers in replyMichal Sojka
When headers contain non-ASCII characters, they are encoded according to rfc2047. Nomtuch reply command emits the headers in the encoded form, which makes them hard to read by humans who compose the reply. For example instead of "Subject: Re: Rozlučka" one currently sees "Subject: Re: =?iso-8859-2?q?Rozlu=E8ka?=". This patch adds a new GMime filter which is used to decode headers to UTF-8 and uses this filter when notmuch reply outputs headers. Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
2010-04-13notmuch.el: quote args in notmuch-show to facilitate remote useJesse Rosenthal
Put single-quotes around the argument of the `show --entire-thread' command in notmuch-show. This change should have no effect on normal usage. However, it allows us to use the notmuch.el client with a remote notmuch binary and database over ssh (by, e.g., setting `notmuch-command' to a simple shell script). Without the quotes, ssh will not send the command properly. One very simple example script is as follows. (Note that it requires keypair login to the ssh server.) #!/bin/sh SSH_BIN="/path/to/local/ssh" NOTMUCH_HOST="my.remote.server" NOTMUCH_REMOTE_PATH="/path/to/remote/notmuch" $SSH_BIN $NOTMUCH_HOST $NOTMUCH_REMOTE_PATH $@
2010-04-13TODO: Note GMime bug that needs to be tested and upstreamed.Carl Worth
This bug was recently noted in a commit message, so we should hold onto it until we've passed it along to the GMime project.
2010-04-13Do not segfault on empty mime partsmartin f. krafft
notmuch previously unconditionally checked mime parts for various properties, but not for NULL, which is the case if libgmime encounters an empty mime part. Upon encounter of an empty mime part, the following is printed to stderr (the second line due to my patch): (process:17197): gmime-CRITICAL **: g_mime_message_get_mime_part: assertion `GMIME_IS_MESSAGE (message)' failed Warning: Not indexing empty mime part. This is probably a bug that should get addressed in libgmime, but for not, my patch is an acceptable workaround. Signed-off-by: martin f. krafft <madduck@madduck.net>
2010-04-13Prevent data loss caused by SIGINT during notmuch newMichal Sojka
When Ctrl-C is pressed in a wrong time during notmuch new, it can lead to removal of messages from the database even if the files were not removed. It happened at least once to me. Signed-off-by: Michal Sojka <sojkam1@fel.cvut.cz>
2010-04-13Fix typo in notmuch.h documentation regarding database open modesMichael Forney
Reviewed-by: Carl Worth <cworth@cworth.org>: The original proposal for having different open modes used the name WRITABLE. I didn't like that name, (easy to misspell as WRITEABLE even for native English speakers). So we renamed it to READ_WRITE immediately, but apparently some of the documentation held the old name for a while.
2010-04-13TODO: Make an explicit note that we need to start testing --format=jsonCarl Worth
The recent fix to handle utf8 in the JSON output is the kind of bug I'd never like to see again, (so that I'd like the test suite to be helping us track that).
2010-04-13Fix json_quote_str to handle non-ASCII charactersGregor Hoffleit
The current code in json_quote_str() only accepts strict printable ASCII code points (i.e. 32-127), all other code points are dropped from the JSON output. The code is attempting to drop only non-printable ASCII characters, but doing a signed comparison of the byte value is also dropping characters with values >= 128. This patch uses an unsigned comparison to accept code points 32-255. Reviewed-by: Carl Worth <cworth@cworth.org> (with some additional details for commit message).
2010-04-13TODO: Note several changes we want to make to the database schema.Carl Worth
Since database upgrades can be fairly painful, we'll want to do all of these within a single release.
2010-04-12lib: Remove condition regarding a NULL parent_thread_id.Carl Worth
A recent change guaranteed that a message ID can never be resolved to a NULL thread ID, so we don't need this extra case.
2010-04-12lib: Always add reference terms to the database.Carl Worth
Previously, we were only adding the reference terms for cases where the referenced message did not yet exist in the database. For thread presentation, it's useful to have the connection information provided by the references, even when the messages are present. So add this term unconditionally.
2010-04-12lib: Document the metadata stored within the Xapian database.Carl Worth
We are currently storing "version", "last_thread_id", and "thread_id_*" values so document how each of these are used.
2010-04-12lib: Fix line-wrapping in _notmuch_database_link_message.Carl Worth
This function had some excessively long lines due to nested expressions. It's simple enough to un-nest these and have readable line lengths.
2010-04-12lib: Fix internal documentation of _notmuch_database_link_messageCarl Worth
This function was recently modified, (to include a metadata lookup for a message's thread ID before looking for parent/child thread IDs), but the documentation wasn't updated. Fix that.
2010-04-12lib: Simplify code flow in _resolve_message_id_to_thread_idCarl Worth
There are two primary cases in this function, (the message exists in the database or it does not). Previously the code for these two cases was split and intermingled with goto-spaghetti connections.
2010-04-12lib: Fix internal documentation of _resolve_message_id_to_thread_idCarl Worth
We no longer return NULL, but instead generate a new thread ID for messages that we haven't seen yet.
2010-04-12Store thread ids for messages that we haven't seen yetJames Westby
This allows us to thread messages even when we receive them out of order, or never receive the root. The thread ids for messages that aren't present but are referred to are stored as metadata in the database and then retrieved if we ever get that message. When determining the thread id for a message we also check for this metadata so that we can thread descendants of a message together before we receive it. Edited by Carl Worth <cworth@cworth.org>: Split this portion of the commit from the earlier-applied portion adding test cases.
2010-04-12test: Add new tests for out-of-order messages.James Westby
These new tests demonstrate a bug as follows: Multiple messages are added to the database All of these message references a common parent The parent message does not exist in the databas In this scenario, the messages will not be recognized as belonging to the same thread. We consider this a bug, and the new tests treat this as a failure. Edited by Carl Worth <cworth@cworth.org>: Split these tests into their own commit (before the fix of the bug). This lets me see the actual failure in the test suite, before the fix is applied. Also fix the alignment of new messages from test suite, (so that the PASS portions all line up---which is important while we're still manually verifying test-suite results).
2010-04-09RELEASING: Update instructions for new version technique.Carl Worth
We pass this in on the "make release" command-line rather than editing the Makefile.
2010-04-09Derive version numbers from gitMichal Sojka
I often have several versions of notmuch compiled and it would be very helpful to be able to distinguish between them. Git has a very nice feature to make intermediate numbering automatic and unambiguous so let's use it here. For tagged versions, the version is the name of the tag, for intermediate versions, the unique ID of the commit is appended to the tag name. When notmuch is compiled from a release tarball, there is no git repository and therefore the tarball contains a special file 'version', which contains the version of release tarball. To create a new release one has to run 'make release VERSION=X.Y'.
2010-04-09nomtuch.1: Add documentation for "notmuch count"Carl Worth
Somehow this has been missing from our manual. Add it now.
2010-04-09notmuch count: Remove unneeded paragraph from documentation.Carl Worth
This paragraph acts like it's introducing an example, but then no example is given. Just drop this.
2010-04-09notmuch count: Remove special handling of "*".Carl Worth
From both the implementation and from the documentation. This is handled generically in the library for all search-based commands, so count doesn't need special treatment.
2010-04-09notmuch: Document the new special-case syntax of "*".Carl Worth
This functionality came through a recent addition to the library.
2010-04-09lib: Handle "*" as a query string to match all messages.Carl Worth
This seems like a generally useful thing to support, (but the previous support through an empty string was not convenient for some users, (such as the command-line client).
2010-04-09Have notmuch count default to showing the total.Mike Kelly
If no parameters are given to notmuch-count, or just '' or '*' are given, return the total number of messages in the database. update notmuch count help
2010-04-07Fix the default value for --includedir.Mike Kelly
2010-04-07debian: Unbreak the build.Carl Worth
I had the wrong syntax for the dh_auto_configure override.
2010-04-07Fix code extracting the MTA from Received: headersDirk Hohndel
The previous code made too many assumptions about the (sadly not standardized) format of the Received headers. This version should be more robust to deal with different variations. Signed-off-by: Dirk Hohndel <hohndel@infradead.org>
2010-04-07emacs: Correct the documentation for notmuch-search-add-tag (and -remove-tag)Carl Worth
These commands act on all messages in the thread, not simply those that match the search. (There are use case for both behaviors, but the documentation must match the behavior that's actually implemented).
2010-04-07notmuch.el: add functionality in notmuch search mode to add or remove tags by regionJesse Rosenthal
This patch adds `-region' versions of the `notmuch-search-' commands to find properties. It also splits up `notmuch-add/remove-tags' into both a `-thread' and a `-region' version. (This makes us modify `notmuch-search-archive-thread' to use the `notmuch-search-remove-tag-thread' function, instead of `notmuch-search-remove-tag', for consistency.) The add/remove-tag command called by pressing `+' or `-' will then choose accordingly, based on whether region is active. This version fixes a couple of errors in the first version, which led to incorrect marking of some tags in the search view (though the actual tagging was still correct). It's also based on current master. I'm not sure any more if region selection is actually the correct way to do this, or if a mutt-style message-marking method would be better. But I didn't want a buggy incorrect version out there.
2010-04-07Display the last few lines of a citation by default.Carl Worth
As put forth in the commit that enabled this functionality, the last few lines of a citation are often much more important. In that case, let's actually do the useful thing by default.
2010-04-07notmuch.el: Allow citation suffixes to be shown as well as prefixes.David Edmondson
In many conversations the last few lines of a citation are more interesting than the first few lines, hence allow those to be shown if desired. Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2010-04-07notmuch.el: Colour cited regions and signatures with message-cited-text-faceDavid Edmondson
Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de> (with fixup to avoid over-eager coloring of signatures).
2010-04-07notmuch.el: colorize lines in notmuch-search based on thread tags.Jameson Rollins
Arbitrary font faces can be specified for given thread tags. By default, no coloring is applied. To specify coloring, place something like this in your .emacs: (setq notmuch-search-line-faces '(("delete" . '(:foreground "red")) ("unread" . '(:foreground "green")))) Order matters: line faces listed first will take precedence (in the example above, a thread tagged both "delete" and "unread" will be colored red, since the "delete" face is listed before the "unread"). notmuch.el | 33 ++++++++++++++++++++++++++++++++- 1 files changed, 32 insertions(+), 1 deletions(-)
2010-04-07emacs: Fix typo in line-wrapping in documentation of notmuch-show.Carl Worth
Just trying to keep things neat.
2010-04-07notmuch.el: Make notmuch-show buffer name first subject, instead of thread-id (supersedes V1--3)Jesse Rosenthal
Change the buffer name to a uniquified subject of the thread (i.e. the subject of the first message in the thread) instead of the thread-id. This is more meaningful to the user, and will make it easier to scroll through numerous open buffers. Note that this patch adds an optional `buffer-name' argument to notmuch show. Signed-off-by: Jesse Rosenthal <jrosenthal@jhu.edu> Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2010-04-07notmuch.el: 'F' in search mode takes us to a list of folders.David Edmondson
2010-04-07notmuch.el: fontify date in headerJameson Rollins
The date was unfairly left out of getting pretty colors in the notmuch-show header display. This fixes that grave injustice. Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2010-04-07Makefile: Install emacs code to site-lisp, not site-lisp/notmuchCarl Worth
And just make the Debian packaging request site-lisp/notmuch like it wants. Otherwise, the installed files won't appear on the load-path so won't be found by emacs.
2010-04-07cleanup style, hopefully no functional changes.acoolon
2010-04-07notmuch-reply: Remove stray brace.Carl Worth
That was breaking the build.
2010-04-07Added tag v0.2.2 for changeset 0122a27667adSebastian Spaeth
2010-04-07Extent pypi documentation. Set version to 0.2.2Sebastian Spaeth
2010-04-06fix obvious cut and paste errorDirk Hohndel
the wrong variable is checked for success of an allocation Signed-off-by: Dirk Hohndel <hohndel@infradead.org>
2010-04-06TODO: Note that "notmuch reply" needs to be tested.Carl Worth
This is a feature that we just added without a test case.
2010-04-06notmuch-reply: Remove a useless level of nesting.Carl Worth
Making the code a tiny bit easier to read (in my opinion at least).
2010-04-06notmuch-reply: Fix some whitespace issues.Carl Worth
No actual code change here. Just whitespace style, (mostly just my preferred space before a left parenthesis, and a space after a comma).