aboutsummaryrefslogtreecommitdiffhomepage
path: root/emacs
Commit message (Collapse)AuthorAge
* emacs: have tag-completion return all tags for nil inputGravatar Jameson Graef Rollins2012-04-12
| | | | | | Previously the function would fail if the initial input was nil. Now it will return a list of all tags, which obviously makes much more sense.
* emacs: include tags from excluded messages in tag tab completionGravatar Jameson Graef Rollins2012-04-12
| | | | | | | The new message exclude functionality will hide tags that only exist on excluded messages. However, one might very well want to manually modify excluded tags. This makes sure tags from excluded messages are always available in tab completion.
* emacs: update call in tag-completion functionGravatar Jameson Graef Rollins2012-04-12
| | | | | "search-tags" is deprecated, so use the more modern and supported "search --output=tags".
* emacs: get rid of trailing spaces in notmuch-hello viewGravatar Dmitry Kurochkin2012-04-12
| | | | | | | | | | | This patch removes trailing spaces in notmuch-hello view. A side effect of this change is that tag/query buttons no longer include a space at the end. This means that pressing RET when the point is at the first character after the tag/query button no longer works (note that this is the standard behavior for buttons). We may change this behavior in the future (without adding trailing spaces back) if people would find this change inconvenient.
* emacs: make show set --exclude=falseGravatar Mark Walters2012-04-07
| | | | | | Show has to set --exclude=false to deal with cases where it is asked to show a single excluded message. It uses JSON so it can easily pass the exclude information to the user.
* emacs: do not modify the alist passed to notmuch-sort-saved-searchesGravatar Jani Nikula2012-04-06
| | | | | | Sort modifies its input as a side effect. Pass it a copy in notmuch-sort-saved-searches to not modify the notmuch-saved-searches alist.
* emacs: fix off-by-one error in notmuch-hello column alignmentGravatar Dmitry Kurochkin2012-04-05
| | | | | Expected results for few tests are fixed, the relevant test is unmarked broken.
* emacs: Fix the References header in replyGravatar Adam Wolfe Gordon2012-04-02
| | | | | | | | | | | | | | In the new reply code, the References header gets inserted by message.el using a function called message-shorten-references. Unlike all the other header-inserting functions, it doesn't put a newline after the header, causing the next header to end up on the same line. In our case, this header happened to be User-Agent, so it's hard to notice. This is probably a bug in message.el, but we need to work around it. This fixes the problem by wrapping message-shorten-references in a function that inserts a newline after if necessary. This should protect against the message.el bug being fixed in the future.
* emacs: Fix two bugs in replyGravatar Adam Wolfe Gordon2012-04-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug 1: Replying from alternate addresses ---------------------------------------- The reply code was inconsistent in its use of symbols and strings for header names being passed to message.el functions. This caused the From header to be lookup up incorrectly, causing an additional From header to be added with the user's primary address instead of the correct alternate address. This is fixed by using symbols everywhere, i.e. never using strings for header names when interacting with message.el. This change also removes our use of `mail-header`, since we don't use it anywhere else, and using assq makes it clear how the header lists are expected to work. Bug 2: Duplicate headers in emacs 23.2 -------------------------------------- The message.el code in emacs 23.2 assumes that header names will always be passed as symbols, so our use of strings caused problems. The symptom was that on 23.2 (and presumably on earlier versions) the reply message would end up with two of some headers. Converting everything to symbols also fixes this issue.
* emacs: Fix mis-named argument to notmuch-get-bodypart-internalGravatar Austin Clements2012-03-31
| | | | | | Previously, this function took an argument called "message-id", even though it was a general query, rather than a message ID. This changes it to "query".
* emacs: Escape all message ID queriesGravatar Austin Clements2012-03-30
| | | | | | | | | | This adds a lib function to turn a message ID into a properly escaped message ID query and uses this function wherever we previously hand-constructed ID queries. Wherever this new function is used, documentation has been clarified to refer to "id: queries" instead of "message IDs". This fixes the broken test introduced by the previous patch.
* emacs: content-type comparison should be case insensitive.Gravatar Mark Walters2012-03-30
| | | | | | | | The function notmuch-match-content-type was comparing content types case sensitively. Fix it so it tests case insensitively. This fixes a bug where emacs would not include any body when replying to a message with content-type TEXT/PLAIN.
* emacs: Use the new JSON reply format and message-cite-originalGravatar Adam Wolfe Gordon2012-03-19
| | | | | | | | | | | | | | | | | Use the new JSON reply format to create replies in emacs. Quote HTML parts nicely by using mm-display-part to turn them into displayable text, then quoting them with message-cite-original. This is very useful for users who regularly receive HTML-only email. Use message-mode's message-cite-original function to create the quoted body for reply messages. In order to make this act like the existing notmuch defaults, you will need to set the following in your emacs configuration: message-citation-line-format "On %a, %d %b %Y, %f wrote:" message-citation-line-function 'message-insert-formatted-citation-line The tests have been updated to reflect the (ugly) emacs default.
* emacs: Factor out useful functions into notmuch-libGravatar Adam Wolfe Gordon2012-03-19
| | | | | Move a few functions related to handling multipart/alternative parts into notmuch-lib.el, so they can be used by future reply code.
* emacs: Fix search tab completion in terminalsGravatar Austin Clements2012-03-18
| | | | | | | | | | | | | | In X, Emacs distinguishes the tab key, which produces a 'tab event; from C-i, which produces a ?\t event. However, in a terminal, these are indistinguishable and only produce a ?\t event. In order to simplify things, Emacs automatically translates from 'tab to ?\t (see "Function key translations" in M-x describe-bindings), so functions only need to be bound to ?\t to work in all situations. Previously, the search tab completion code usedq (kbd "<tab>"), which produced the event sequence [tab], which only matched the 'tab event and hence only worked in X. This patch changes it to (kbd "TAB"), which matches the general ?\t event and works in all situations.
* Merge branch 'release'Gravatar David Bremner2012-03-10
|\
| * emacs: fix MML quoting in repliesGravatar Jani Nikula2012-03-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The reply MML quoting added in commit ae438cc unintentionally MML quotes also the signature/encryption MML tags added via message-setup-hook, causing the reply not to be signed/encrypted. MML quote just the original message in the temp buffer before inserting it to the message buffer, to not interfere with message mode hooks or message construction in general. See [1] and [2] for bug reports. Thanks to Tim Bielawa <tbielawa@redhat.com> for testing. [1] id:"87hay78x6l.fsf@wyzanski.jamesvasile.com" [2] id:"1330812262-28272-1-git-send-email-tbielawa@redhat.com". Signed-off-by: Jani Nikula <jani@nikula.org>
* | emacs-hello: Do not calculate the count of the messages in hidden sectionsGravatar Michal Sojka2012-03-10
| | | | | | | | | | The result is that hello screen shows much faster when some sections are hidden.
* | Merge branch 'release'Gravatar David Bremner2012-03-03
|\|
* | emacs: notmuch.el ignore excluded matchesGravatar Mark Walters2012-03-02
| | | | | | | | | | | | | | | | This is a small change to make notmuch.el ignore excluded matches. In the future it could do something better like add a button for rerunning the search with the excludes (particularly if nothing matches with the excludes) or having them invisible and allowing the visibility to be toggled.
* | emacs: show: recognize the exclude flag.Gravatar Mark Walters2012-03-02
| | | | | | | | | | | | | | Show mode will recognize the exclude flag by not opening excluding messages by default, and will start at the first matching non-excluded message. If there are no matching non-excluded messages it will go to the first matching (necessarily excluded) message.
| * Spelling fixGravatar Tomi Ollila2012-03-01
| | | | | | | | Retreive is spelled as r e t r i e v e .
| * emacs: retain show buffer state after retrieving gpg keyGravatar Tomi Ollila2012-03-01
| | | | | | | | | | | | | | | | After retrieving gpg key retain show buffer state like in all other operations (i.e. no other calls to notmuch-show-refresh-view provides optional reset-state argument). Emacs MUA keeps current message under cursor instead of going first open message(possibly marking it read).
* | emacs: User-defined sections in notmuch-helloGravatar Daniel Schoepe2012-03-01
|/ | | | | | | | | | This patch makes the notmuch-hello screen fully customizable by allowing the user to add and remove arbitrary sections. It also provides some convenience functions for constructing sections, e.g. showing the unread message count for each tag. This is done by specifying a list of functions that will be run when notmuch-hello is invoked.
* emacs: Clarify description of thread manipulating functionsGravatar Michal Sojka2012-02-29
| | | | | | | | | | | It is not clear whether the term "thread" refers to the thread in the database or to the thread currently shown in a buffer. Those two meanings may refer to different sets of messages, e.g. when a new email is added to the database while the buffer shows the state before the new email arrived. This patch replaces the term thread with the term current buffer, which is hopefully less ambiguous.
* emacs: Fix out of date commentGravatar Austin Clements2012-02-27
| | | | | | The behavior of the header line in show-mode changed from showing the subject of the first open message to showing the subject of the first message in 4d77f18b. Update a comment to reflect this.
* emacs: Reverse the meaning of notmuch-show-refresh-view's argumentGravatar Austin Clements2012-02-25
| | | | | | | | Consensus seems to be that people prefer that refreshing show buffers retains state by default, rather than resetting it by default. This turns out to be the case in the code, as well. In fact, there's even a test for this that's been marked broken for several months, which this patch finally gets to mark as fixed.
* emacs: When refreshing a show buffer, only mark read when resetting stateGravatar Austin Clements2012-02-25
| | | | | | | | | | | | | | | If we retain state while refreshing a show buffer, it should not mark any messages read since it's not a navigation operation (it especially shouldn't mark the first message matching the query read, which is what it did previously). If the user or caller requests that refresh reset the state of the buffer, then we consider that a navigation operation, so we do mark the message under point after the refresh read. This is implemented by moving responsibility for initial positioning and read-marking out of notmuch-show-worker and into its caller. Since notmuch-show-worker is now exclusively about building the show buffer, we rename it to notmuch-show-build-buffer.
* emacs: add `notmuch-show-stash-mlarchive-link{, -and-go}'Gravatar Pieter Praet2012-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * emacs/notmuch-show.el (notmuch-show-stash-mlarchive-link-alist): New defcustom of type `alist' (key = name, value = URI), containing Mailing List Archive URI's for searching by Message-Id. (notmuch-show-stash-mlarchive-link-default): New defcustom, default MLA to use when `notmuch-show-stash-mlarchive-link' received no user input whatsoever. Available choices are generated using the contents of `notmuch-show-stash-mlarchive-link-alist'. (notmuch-show-stash-map): Added keybinds "l" and "L" for `notmuch-show-stash-mlarchive-link' respectively `notmuch-show-stash-mlarchive-link-and-go'. (notmuch-show-stash-mlarchive-link): New function, stashes a URI pointing to the current message at one of the MLAs configured in `notmuch-show-stash-mlarchive-link-alist'. Prompts user with `completing-read' if not provided with an MLA key. (notmuch-show-stash-mlarchive-link-and-go): New function, uses `notmuch-show-stash-mlarchive-link' to stash a URI, and then visits it using the browser configured in `browse-url-browser-function'. Based on original work [1] by David Edmondson <dme@dme.org>. [1] id:"1327397873-20596-1-git-send-email-dme@dme.org"
* emacs: `notmuch-show-get-message-id': optionally return Message-Id sans prefixGravatar Pieter Praet2012-02-25
| | | | | | | | | | | | * emacs/notmuch-show.el (notmuch-show-get-message-id): Add optional arg BARE. When non-nil, return a Message-Id without quotes and prefix, thus obviating the need to strip them off again in various places. (notmuch-show-stash-message-id-stripped): Update wrt changes in `notmuch-show-get-message-id'.
* emacs: support text/calendar mime typeGravatar Jani Nikula2012-02-25
| | | | | | | Replace text/x-vcalendar with text/calendar, while maintaining support and backwards compatibility for text/x-vcalendar. Code by David Edmondson <dme@dme.org>
* emacs: Fix out-of-date declare-functionGravatar Austin Clements2012-02-20
| | | | | The names of the arguments to notmuch-show-refresh-view had gotten out of sync between the declare-function and the real thing.
* emacs: Fix display of highlighted line in notmuch-searchGravatar Michal Sojka2012-02-17
| | | | | | | When notmuch-search-line-faces is used to set background color in search results, the highlight of the current line is not always displayed correctly. This patch fixes that by increasing the priority property of the highlight overlay.
* emacs: allow to set RETAIN-STATE for `notmuch-show-refresh-view' interactivelyGravatar Dmitry Kurochkin2012-02-14
| | | | | | The notmuch-show view refresh function (`notmuch-show-refresh-view', bound to "=") accepts an optional RETAIN-STATE argument. The patch allows to set this argument interactively by using "C-u =".
* emacs: cleanup and simplify `notmuch-show-archive-thread' and related functionsGravatar Dmitry Kurochkin2012-02-12
| | | | | | | | | | | | Recent changes in notmuch-show tagging introduced some code duplication. The patch cleanups and simplifies `notmuch-show-archive-thread' function by using `notmuch-show-tag-all', no longer used function are removed. After the change, `notmuch-show-archive-thread' function becomes symmetric with `notmuch-show-archive-message'. A side effect of these changes is that `notmuch-show-archive-thread' no longer calls "notmuch tag" for each message in the thread.
* emacs: A prefix argument to `notmuch-show' should invert the matching ↵Gravatar David Edmondson2012-02-12
| | | | | | | | message behaviour. Allow the user to open a thread with inverted `notmuch-show-only-matching-messages' behaviour using a prefix argument.
* emacs: Add `notmuch-show-only-matching-messages'.Gravatar David Edmondson2012-02-12
| | | | | Allow the user to choose that only matching messages are shown by default.
* emacs: Check that the parent buffer is alive before using it.Gravatar David Edmondson2012-02-12
|
* emacs: Optionally retain the state of the buffer during ↵Gravatar David Edmondson2012-02-12
| | | | | | | | | | | | | | | `notmuch-show-refresh-view'. With an argument, record and reply the state of the buffer during `notmuch-show-refresh-view'. In this context, "state" is defined as: - the open/closed state of each message, - the current message. Traditional use of refresh with the = key does not retain the state. The recently introduced toggle commands ($, !, < and >) do retain the state.
* emacs: Add a binding (t) to toggle the truncation of long lines.Gravatar David Edmondson2012-02-12
|
* emacs: Allow the indentation of content to be toggled.Gravatar David Edmondson2012-02-12
| | | | | | | | | Very deeply indented content is sometimes difficult to read (particular for something like patches). Allow the indentation of the content to be toggled with '<'. Indentation of the header lines is not affected, so it remains possible to see the structure of the thread.
* emacs: Allow `notmuch-show-mode' to display only matching messages.Gravatar David Edmondson2012-02-12
| | | | | | | The current behaviour (all messages shown, non-matching collapsed) is retained as the default. Type '!' to switch to showing only the matching messages - non-matching messages are not available. '!' will switch back to showing everything.
* emacs: Rework crypto switch toggle.Gravatar David Edmondson2012-02-12
| | | | | | | | | | | | | | Re-work the existing crypto switch toggle to be based on a persistant buffer-local variable. To allow this, modify `notmuch-show-refresh-view' to erase and re-draw in the current buffer rather than killing the current buffer and creating a new one. (This will also allow more per-buffer behaviour in future patches.) Add a binding ('$') to toggle crypto processing of the current buffer and remove the prefix argument approach that achieves a similar result.
* emacs: Ensure that gnupg output goes at the end of the buffer.Gravatar David Edmondson2012-02-12
| | | | | | | When showing the user some details of gnupg output, ensure that those details are shown at the end of the gnupg status buffer ("*notmuch-crypto-gpg-out*"), otherwise it can end up mixed up with earlier output.
* emacs: add default value to notmuch-search-line-facesGravatar Jani Nikula2012-02-12
| | | | | | | | | | | | | | Add default value to notmuch-search-line-faces to show "unread" messages in bold, and "flagged" messages in blue, to have some visual indication of important messages in search results. This should be helpful for new users. "unread" tag is quite obvious, and handled specially both in the lib and emacs ui. "flagged" is synced to maildir F flag in the lib. If one syncs the maildir to IMAP, this also translates to corresponding IMAP flag. (This is "starred" in GMail and Android.) Signed-off-by: Jani Nikula <jani@nikula.org>
* emacs: make show view a/A/x/X key bindings more consistentGravatar Jani Nikula2012-02-08
| | | | | | | | | | | | | | | | | | | | | Modify the show view key bindings as follows to make them more consistent: 'a' = Archive current message, then move to next message, or show next thread from search if at the last message in thread. 'A' = Archive each message in thread, then show next thread from search. 'x' = Archive current message, then move to next message, or exit back to search results if at the last message in thread. 'X' = Archive each message in thread, then exit back to search results. The changes make the key bindings more consistent in two ways: 1) 'a'/'A' both advance to the next thread like 'a' used to. 2) 'x' operates on messages and 'X' on threads like 'a'/'A'.
* emacs: s/tags/tag-changes/ for arguments of tagging functionsGravatar Dmitry Kurochkin2012-02-08
| | | | | | | This makes the argument names more consistent and clear. The following functions changed: `notmuch-tag', `notmuch-search-tag-thread', `notmuch-search-tag-region' and `notmuch-search-tag-all'.
* emacs: accept empty tag list in `notmuch-tag'Gravatar Dmitry Kurochkin2012-02-08
| | | | | | | Since `notmuch-tag' is a non-interactive function and hence is meant to be invoked programmatically, it should accept zero tags. Also, the tagging operations (bound to "*", "+", "-") would accept empty input without an error.
* emacs: relax tag syntax check in `notmuch-tag' functionGravatar Dmitry Kurochkin2012-02-08
| | | | | | | | The tag syntax check in `notmuch-tag' function was too strict and did not allow nmbug tags with "::". Since the check is done for all tagging operations in Emacs UI, this basically means that no nmbug tags can be changed. The patch relaxes the tag syntax check to allow any tag names that do not include whitespace characters.
* emacs: separate history for operations which accept single and multiple tagsGravatar Dmitry Kurochkin2012-02-08
| | | | | | | | | | | | Some tag-related operations accept a single tag without prefix (`notmuch-select-tag-with-completion'), others accept multiple tags prefixed with '+' or '-' (`notmuch-read-tag-changes'). Before the change, both functions used a single default minibuffer history. This is inconvenient because you have to skip options with incompatible format when going through the history. The patch adds separate history lists for the two functions. Note that functions that accept the same input format (e.g. "+", "-", "*") share the history list as before.