aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2013-07-01man: document insert --folder optionPeter Wang
Add documentation for notmuch insert --folder option.
2013-07-01insert: add --folder optionPeter Wang
Allow the new message to be inserted into a folder within the Maildir hierarchy instead of the top-level folder.
2013-06-29test: add tests for insertPeter Wang
Add tests for new 'insert' command.
2013-06-29man: reference notmuch-insert.1Peter Wang
Add references to notmuch-insert.1 from other man pages.
2013-06-29man: document 'insert' commandPeter Wang
Add initial documentation for notmuch insert command.
2013-06-29cli: add insert commandPeter Wang
The notmuch insert command reads a message from standard input, writes it to a Maildir folder, and then incorporates the message into the notmuch database. Essentially it moves the functionality of notmuch-deliver into notmuch. Though it could be used as an alternative to notmuch new, the reason I want this is to allow my notmuch frontend to add postponed or sent messages to the mail store and notmuch database, without resorting to another tool (e.g. notmuch-deliver) nor directly modifying the maildir.
2013-06-29tag-util: do not reset list in parse_tag_command_linePeter Wang
The 'insert' command will be better served if parse_tag_command_line modifies a pre-populated list (of new.tags) instead of clobbering the list outright. The sole existing caller, notmuch_tag_command, is unaffected by this change.
2013-06-29tag-util: move out 'tag' command-line checkPeter Wang
Move an error condition specific to the 'tag' command out of parse_tag_command_line so that parse_tag_command_line can be used for the forthcoming 'insert' command.
2013-06-25contrib: pick: remove reference to inbox in docstringMark Walters
Copy the recent changes in show to use just notmuch-archive-tags (as a link) rather than saying '(defaults to "inbox")'.
2013-06-24emacs: Remove `notmuch-call-notmuch-json'Austin Clements
This function is no longer used.
2013-06-24emacs: Use S-exp format everywhereAustin Clements
This switches `notmuch-mua-reply' and `notmuch-query-get-threads' to the S-exp format. These were the last two uses of the JSON format in the Emacs frontend.
2013-06-24emacs: Introduce `notmuch-call-notmuch-sexp'Austin Clements
This is just like `notmuch-call-notmuch-json', but parses S-expression output. Note that, also like `notmuch-call-notmuch-json', this doesn't consider trailing data to be an error, which may or may not be what we want in the long run.
2013-06-24cli: use notmuch_exclude_t in option parserPeter Wang
Use notmuch_exclude_t constants directly instead of a redundant enumeration while parsing search --exclude keyword arguments.
2013-06-24lib: add NOTMUCH_EXCLUDE_FLAG to notmuch_exclude_tMark Walters
Add NOTMUCH_EXCLUDE_FLAG to notmuch_exclude_t so that it can cover all four values of search --exclude in the cli. Previously the way to avoid any message being marked excluded was to pass in an empty list of excluded tags: since we now have an explicit option we might as well honour it. The enum is in a slightly strange order as the existing FALSE/TRUE options correspond to the new NOTMUCH_EXCLUDE_FLAG/NOTMUCH_EXCLUDE_TRUE options so this means we do not need to bump the version number. Indeed, an example of this is that the cli count and show still use FALSE/TRUE and still work.
2013-06-24revert: Removed top level --stderr= optionTomi Ollila
While looked good on paper, its attempted use caused confusion, complexity, and potential for information leak when passed through wrapper scripts. For slimmer code and to lessen demand for maintenance/support the set of commits which added top level --stderr= option is now reverted.
2013-06-24emacs: Remove v commandAustin Clements
This removes the v command, since we now have much nicer part commands, and deprecates the underlying notmuch-show-view-all-mime-parts. This also means that people who try using the old unprefixed 'v' command on a part button will no longer be greeted by ALL of their parts popping up.
2013-06-24emacs: update search sort order help to match codeJani Nikula
2013-06-24test/basic: replaced find -perm +111 with portable alternativeTomi Ollila
The find option syntax `-perm +111` is deprecated gnu find feature. The replacement `( -perm -100 -o -perm -10 -o -perm 1 )` should also work outside of the GNU domain.
2013-06-24emacs: show: change emacs interactive pipe message.Mark Walters
Previously the query string for piping a message to a command was "Pipe message to command: " regardless of whether the function was called with a prefix argument (which pipes all open messages to the command). This patch modifies the `interactive' command to reflect this.
2013-06-13emacs: show: implement lazy hidden part handlingMark Walters
This adds the actual code to do the lazy insertion of hidden parts. We use a memory inefficient but simple method: when we come to insert the part if it is hidden we just store all of the arguments to the part insertion function as a button property. This means when we want to show the part we can just resume where we left off. One thing is that we can't tell if a lazy part will produce text until we try to render it so when unhiding a part we check to see if it rendered; if not we invoke the default part handler (e.g. an external viewer). Also, we would like to insert the lazy part at the start of the line after the part button. But if this line has some text properties (e.g. the colours for a following message header) then the lazy part gets these properties. Thus we start at the end of the part button line, insert a newline, insert the lazy part, and then delete the extra newline at the end of the part.
2013-06-13emacs: show move addition of :notmuch-part to separate functionMark Walters
This separates out the adding of the :notmuch-part text property to a separate function to simplify calling from the lazy part insertion code.
2013-06-13emacs: show: modify the way hidden state is recorded.Mark Walters
Previously, whether a part was hidden or shown was recorded in the invisibility/visibility of the part overlay. Since we are going to have lazily rendered parts with no overlay store the hidden/shown state in the part button itself. Additionally, in preparation for the invisible part handling move the actual hiding of the hidden parts to insert-bodypart from create-part-overlays. Finally, we will need to know whether a part-insertion has done anything (it won't if the invisible part cannot be displayed by emacs) so we slightly rejig the code order in notmuch-show-toggle-part-invisibility to make it easier for the function to set an appropriate return value.
2013-06-13emacs: show: pass button to create-overlaysMark Walters
Now that the bodypart code has the button we can pass that to create-overlays and simplify that.
2013-06-13emacs: show: move the insertion of the header button to the top levelMark Walters
Previously each of the part insertion handlers inserted the part button themselves. Move this up into notmuch-show-insert-bodypart. Since a small number of the handlers modify the button (the encryption/signature ones) we need to pass the header button as an argument into the individual part insertion handlers. However, the declared-type argument was only used for the text for the part buttons we can now omit it. The patch is large but mostly simple. The only things of note are that we let the text/plain handler applies notmuch-wash to the whole part including the part button. In particular, notmuch-wash removes leading blank lines from a text/plain part, but since the button is counted as part of the part this does not happen with text/plain buttons that have a button. This is probably a bug in notmuch-wash but changing it does make several tests fail (that rely on this blank line) so, for the moment, keep the old behaviour.
2013-06-13emacs: show: fake wash parts are handled at insert-bodypart levelMark Walters
Earlier patches have moved the handling of wash fake inline patch parts to insert-bodypart so we can drop the function notmuch-show-insert-part-inline-patch-fake-part
2013-06-12emacs: Fix "no such file or directory" errorAustin Clements
Occasionally, when the user killed the search buffer when the CLI process was still running, Emacs would run the notmuch-start-notmuch-sentinel sentinel twice. The first call would process and delete the error output file and the second would fail with an "Opening input file: no such file or directory, ..." error when attempting to access the error file. Emacs isn't supposed to run the sentinel twice. The reason it does is rather subtle (and probably a bug in Emacs): 1) When the user kills the search buffer, Emacs invokes kill_buffer_processes, which sends a SIGHUP to notmuch, but doesn't do anything else. Meanwhile, suppose the notmuch search process has printed some more output, but Emacs hasn't consumed it yet (this is critical and is why this error only happens sometimes). 2) Emacs gets a SIGCHLD from the dying notmuch process, which invokes handle_child_signal, which sets the new process status, but can't do anything else because it's a signal handler. 3) Emacs returns to its idle loop, which calls status_notify, which sees that the notmuch process has a new status. This is where things get interesting. 3.1) Emacs guarantees that it will run process filters on any unconsumed output before running the process sentinel, so status_notify calls read_process_output, which consumes the final output and calls notmuch-search-process-filter. 3.1.1) notmuch-search-process-filter checks if the search buffer is still alive and, since it's not, it calls delete-process. 3.1.1.1) delete-process correctly sees that the process is already dead and doesn't try to send another signal, *but* it still modifies the status to "killed". To deal with the new status, it calls status_notify. Dun dun dun. We've seen this function before. 3.1.1.1.1) The *recursive* status_notify invocation sees that the process has a new status and doesn't have any more output to consume, so it invokes our sentinel and returns. 3.2) The outer status_notify call (which we're still in) is now done flushing pending process output, so it *also* invokes our sentinel. This patch addresses this problem at step 3.1.1, where the filter calls delete-process, since this is a strange and redundant thing to do anyway.
2013-06-12emacs: Don't report CLI signals sent by Emacs as errorsAustin Clements
Previously, when the user killed the search buffer before the CLI search process had completed, we would report the signal sent by Emacs to kill the CLI to the user as an error. Fix this by only reporting error exits if the process buffer is still live. We still report stderr output regardless in case stderr output was relevant to why the user killed the search buffer (such as a wrapper script being stuck).
2013-06-08cli: Guard deprecated g_type_init callsTomi Ollila
g_type_init was deprecated in GLib 2.35.1. In order to compile cleanly, guard these with a suitable #if. (commit msg from https://bugs.freedesktop.org/attachment.cgi?id=73774 )
2013-06-08emacs: hello: allow deleting individual searches in the historyServilio Afre Puentes
This commit adds an extra button at the end of the search entries that allows deleting that individual search from the history. A short confirmation («y» or «n») is made before taking action.
2013-06-08emacs: hello: ask confirmation for clearing recent searchesServilio Afre Puentes
The button to clear the recent searches in notmuch-hello is easy to press accidentally while moving around the, clearing potentially useful searches with no way of recovering them.
2013-06-04debian: update build dependency to require ruby-dev 1:1.9.3Jameson Graef Rollins
ruby1.8-dev provides ruby-dev, but ruby1.9.1-dev is currently required (which is pulled by ruby-dev 1:1.9.3).
2013-06-04contrib: pick: remove unnecessary funcallMark Walters
Remove unnecessary funcall. This keeps the pick function inline with the recently tweaked show function.
2013-06-04news: Be louder about s/v/o/| on part buttons going awayAustin Clements
This change is likely to affect most people, so put this information right in the news header and be more explicit about it in the news detail.
2013-06-04emacs: Fix applying stickiness to the :notmuch-part propertyAustin Clements
Previously, we simply called pushnew to add :notmuch-part to the front-sticky and rear-nonsticky text property lists. This works if these are nil or lists, but they can also have the value t, meaning that all properties are front-sticky/rear-nonsticky. In this case, pushnew will signal an error because t is not a list. We never set these properties to t ourselves, but since we apply these property changes over arbitrary renderer output, we have to deal with this possibility.
2013-06-03bindings/go: Start a .gitignore for go bindings.David Bremner
In particular ignore downloaded source from github.com
2013-06-03bindings/python: ignore build subdirectory.David Bremner
Update .gitignore to make git status less noisy
2013-06-02vim: use the old vim plugin function nameFelipe Contreras
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
2013-06-02NEWS: update news about the vim interfaceFelipe Contreras
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
2013-06-02Add new notmuch vim pluginFelipe Contreras
The old one was not properly maintained and is now deprecated. The new one has much better support. Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
2013-06-02contrib: pick: bugfix: use notmuch-show-mark-read-tags instead of unreadMark Walters
Previously pick removed the unread tag from its tag display: since the tag change is now customisable use the customised variable. This only affected the tags displayed, not the tags in the database as notmuch-show (in the view pane) did the actual tag changes.
2013-06-02contrib: pick: bugfix. use notmuch-show-only-matching-messages rather than prefixMark Walters
Previously pick set a prefix argument prior to calling show in the message pane to tell show to only show matching messages. This sets notmuch-show-only-matching-messages instead which is much cleaner and will work even if the user has configured show to default to showing only matching messages.
2013-06-02build: pass CPPFLAGS to C and C++ compilersDavid Bremner
This is used in particular by hardening flags.
2013-06-02configure: grab CPPFLAGS from the environment.David Bremner
This is needed in particular for hardening flags.
2013-06-02debian: compile with V=1David Bremner
The idea is to allow hardening verification tools (in particular blhc) to scan the logs. Actually fixing the problem will require modifying the notmuch configure script to propagate CPPFLAGS.
2013-06-02debian: update .gitignoreDavid Bremner
Several packages have been added or renamed, but their build detritus not yet ignored.
2013-06-02emacs: update .gitignoreDavid Bremner
Start a seperate .gitignore for emacs stuff, move .elc rule there.
2013-06-02emacs: add `notmuch-archive-tags' cross references in docstringsDavid Bremner
Several function docstrings refer to behaviour in docstrings that is really controlled by notmuch-archive-tags. Add cross references, and replace hardcoding.
2013-06-02emacs: remove hardcoded defaults values from docstringsDavid Bremner
These functions refer to default values of variables, but it seems less confusing and less likely to get out of date to just allow the user to follow the help cross-reference links.
2013-06-02NEWS: key bindings for next/previous threadJani Nikula
2013-06-02emacs: replace setq + let with let*David Bremner
I found several places where a setq is immediately followed by a let or a let*. This seems to be the pessimal combination, with the implicit scope of the setq combined with the extra indentation of the let. I combined these cases into a single let* which I think is easier to read.