notmuch
11 years agovim: include stubs for Tab-ing thorugh folds in show view
Bart Trojanowski [Tue, 24 Nov 2009 01:26:28 +0000 (20:26 -0500)]
vim: include stubs for Tab-ing thorugh folds in show view

11 years agovim: include search terms when showing message
Bart Trojanowski [Tue, 24 Nov 2009 01:25:47 +0000 (20:25 -0500)]
vim: include search terms when showing message

11 years agovim: fix '?' command in message display
Bart Trojanowski [Tue, 24 Nov 2009 01:24:22 +0000 (20:24 -0500)]
vim: fix '?' command in message display

11 years agovim: fix shell escaping for () in search terms
Bart Trojanowski [Tue, 24 Nov 2009 01:23:41 +0000 (20:23 -0500)]
vim: fix shell escaping for () in search terms

11 years agovim: fix column formatting for >9 messages in search view
Bart Trojanowski [Tue, 24 Nov 2009 01:20:34 +0000 (20:20 -0500)]
vim: fix column formatting for >9 messages in search view

11 years agovim: preserve previous buffer number when refreshing search
Bart Trojanowski [Tue, 24 Nov 2009 01:05:51 +0000 (20:05 -0500)]
vim: preserve previous buffer number when refreshing search

11 years agovim: add git-diff.vim in README, make syntax work w/o the script
Bart Trojanowski [Mon, 23 Nov 2009 14:28:40 +0000 (09:28 -0500)]
vim: add git-diff.vim in README, make syntax work w/o the script

11 years agovim: cleanup tag filtering
Bart Trojanowski [Sun, 22 Nov 2009 22:17:20 +0000 (17:17 -0500)]
vim: cleanup tag filtering

Given an existing search expression and a regular filter, the resulting
search will be:

        EXISTING AND ( NEW )

With a tag filter each of the tags given will be prefixed with tag: and
separated by AND.

11 years agovim: cleanup a few minor glitches
Bart Trojanowski [Sun, 22 Nov 2009 20:59:27 +0000 (15:59 -0500)]
vim: cleanup a few minor glitches

11 years agovim: fix an error in the logic for finding message under cursor in show screen
Bart Trojanowski [Sun, 22 Nov 2009 05:42:42 +0000 (00:42 -0500)]
vim: fix an error in the logic for finding message under cursor in show screen

11 years agovim: use ,s for editing search query
Bart Trojanowski [Sun, 22 Nov 2009 05:35:38 +0000 (00:35 -0500)]
vim: use ,s for editing search query

(save 'S' for marking things as spam)

11 years agovim: have ? show details of what's under cursor in search/show views
Bart Trojanowski [Sun, 22 Nov 2009 05:29:57 +0000 (00:29 -0500)]
vim: have ? show details of what's under cursor in search/show views

11 years agovim: ingore would-be-folds with line count of 1 or fewer
Bart Trojanowski [Sun, 22 Nov 2009 05:16:25 +0000 (00:16 -0500)]
vim: ingore would-be-folds with line count of 1 or fewer

11 years agovim: added searching for word under cursor with ^]
Bart Trojanowski [Sun, 22 Nov 2009 05:10:27 +0000 (00:10 -0500)]
vim: added searching for word under cursor with ^]

11 years agovim: highlight []-blocks in search view
Bart Trojanowski [Sun, 22 Nov 2009 04:59:01 +0000 (23:59 -0500)]
vim: highlight []-blocks in search view

11 years agovim plugin: removed some dead code
Bart Trojanowski [Sun, 22 Nov 2009 04:52:24 +0000 (23:52 -0500)]
vim plugin: removed some dead code

11 years agovim: place ... more inteligently when shortening 'from' list in search
Bart Trojanowski [Sun, 22 Nov 2009 04:48:39 +0000 (23:48 -0500)]
vim: place ... more inteligently when shortening 'from' list in search

11 years agofix returning to folders after searching a few times
Bart Trojanowski [Sun, 22 Nov 2009 04:17:41 +0000 (23:17 -0500)]
fix returning to folders after searching a few times

11 years agomake searching, updates and returning to folder view work
Bart Trojanowski [Sun, 22 Nov 2009 04:14:53 +0000 (23:14 -0500)]
make searching, updates and returning to folder view work

11 years agoadd notmuch-folders support mode
Bart Trojanowski [Sun, 22 Nov 2009 03:24:54 +0000 (22:24 -0500)]
add notmuch-folders support mode

11 years agoremove some debug code from NM_cmd_search()
Bart Trojanowski [Sun, 22 Nov 2009 02:33:41 +0000 (21:33 -0500)]
remove some debug code from NM_cmd_search()

11 years agoNM_show_prev() -> NM_show_previous()
Bart Trojanowski [Sat, 21 Nov 2009 23:34:51 +0000 (18:34 -0500)]
NM_show_prev() -> NM_show_previous()

11 years agocorrect fold line counts
Bart Trojanowski [Sat, 21 Nov 2009 05:04:52 +0000 (00:04 -0500)]
correct fold line counts

11 years agokeep the ,nmr hack around
Bart Trojanowski [Fri, 20 Nov 2009 20:53:46 +0000 (15:53 -0500)]
keep the ,nmr hack around

11 years agoclear the nmap before creating our bindings
Bart Trojanowski [Fri, 20 Nov 2009 20:47:25 +0000 (15:47 -0500)]
clear the nmap before creating our bindings

11 years agodon't fold single lines
Bart Trojanowski [Fri, 20 Nov 2009 20:47:01 +0000 (15:47 -0500)]
don't fold single lines

11 years agoavoid reloading search screen when we add/remove tags
Bart Trojanowski [Fri, 20 Nov 2009 20:42:42 +0000 (15:42 -0500)]
avoid reloading search screen when we add/remove tags

11 years agodebug code to measure how long calls to system() take
Bart Trojanowski [Fri, 20 Nov 2009 20:42:18 +0000 (15:42 -0500)]
debug code to measure how long calls to system() take

11 years agomake control-p go to previous message
Bart Trojanowski [Fri, 20 Nov 2009 20:23:02 +0000 (15:23 -0500)]
make control-p go to previous message

11 years agolot more stubs for future keybindings
Bart Trojanowski [Fri, 20 Nov 2009 19:53:46 +0000 (14:53 -0500)]
lot more stubs for future keybindings

11 years agoimplemented folding bodies and headers
Bart Trojanowski [Fri, 20 Nov 2009 19:18:42 +0000 (14:18 -0500)]
implemented folding bodies and headers

11 years agomore endless toil with syntax
Bart Trojanowski [Fri, 20 Nov 2009 18:50:29 +0000 (13:50 -0500)]
more endless toil with syntax

11 years agofix after merge, --reverse replaced with --sort=
Bart Trojanowski [Fri, 20 Nov 2009 17:37:52 +0000 (12:37 -0500)]
fix after merge, --reverse replaced with --sort=

11 years agocrude order toggle
Bart Trojanowski [Fri, 20 Nov 2009 17:16:32 +0000 (12:16 -0500)]
crude order toggle

11 years agoadded search filtering
Bart Trojanowski [Fri, 20 Nov 2009 17:05:43 +0000 (12:05 -0500)]
added search filtering

11 years agoadded support for archive command
Bart Trojanowski [Fri, 20 Nov 2009 16:13:49 +0000 (11:13 -0500)]
added support for archive command

11 years agocleanup calls to script functions, use <SID>
Bart Trojanowski [Fri, 20 Nov 2009 15:59:31 +0000 (10:59 -0500)]
cleanup calls to script functions, use <SID>

11 years agofix showing thread
Bart Trojanowski [Fri, 20 Nov 2009 15:58:34 +0000 (10:58 -0500)]
fix showing thread

11 years agoadded tagging and refresh to search screen
Bart Trojanowski [Fri, 20 Nov 2009 15:57:25 +0000 (10:57 -0500)]
added tagging and refresh to search screen

11 years agoadd dummy entries to search screen keymap
Bart Trojanowski [Fri, 20 Nov 2009 15:19:31 +0000 (10:19 -0500)]
add dummy entries to search screen keymap

11 years agodefine keymap for show screen as a dictionary
Bart Trojanowski [Fri, 20 Nov 2009 14:56:10 +0000 (09:56 -0500)]
define keymap for show screen as a dictionary

11 years agocleanup default handling code
Bart Trojanowski [Fri, 20 Nov 2009 14:49:11 +0000 (09:49 -0500)]
cleanup default handling code

11 years agomake search screen mappings configurable via dictionary
Bart Trojanowski [Fri, 20 Nov 2009 14:42:29 +0000 (09:42 -0500)]
make search screen mappings configurable via dictionary

11 years agomake it possible to set config options from outside the script
Bart Trojanowski [Fri, 20 Nov 2009 14:35:12 +0000 (09:35 -0500)]
make it possible to set config options from outside the script

11 years agotoggle signatures and citations with s/c respectively
Bart Trojanowski [Fri, 20 Nov 2009 06:57:57 +0000 (01:57 -0500)]
toggle signatures and citations with s/c respectively

11 years agofix a corner case with folding a single line citation
Bart Trojanowski [Fri, 20 Nov 2009 06:39:22 +0000 (01:39 -0500)]
fix a corner case with folding a single line citation

11 years agoadded ^n to handle walking messages
Bart Trojanowski [Fri, 20 Nov 2009 06:35:33 +0000 (01:35 -0500)]
added ^n to handle walking messages

11 years agopretty colouring and folding for message show
Bart Trojanowski [Fri, 20 Nov 2009 06:15:00 +0000 (01:15 -0500)]
pretty colouring and folding for message show

11 years agoparsing rewritten one more time
Bart Trojanowski [Fri, 20 Nov 2009 06:13:50 +0000 (01:13 -0500)]
parsing rewritten one more time

11 years agocompletely rewritten show handling
Bart Trojanowski [Fri, 20 Nov 2009 03:47:09 +0000 (22:47 -0500)]
completely rewritten show handling

11 years agofirst attempt to fold the message nicely
Bart Trojanowski [Thu, 19 Nov 2009 21:20:16 +0000 (16:20 -0500)]
first attempt to fold the message nicely

11 years agofolding for citations
Bart Trojanowski [Thu, 19 Nov 2009 17:35:41 +0000 (12:35 -0500)]
folding for citations

11 years agonaively fold all signatures
Bart Trojanowski [Thu, 19 Nov 2009 17:30:59 +0000 (12:30 -0500)]
naively fold all signatures

11 years agograb all the pattern matchers from the emacs script
Bart Trojanowski [Thu, 19 Nov 2009 17:30:38 +0000 (12:30 -0500)]
grab all the pattern matchers from the emacs script

11 years agomake <Enter> from search screen display the correct message
Bart Trojanowski [Thu, 19 Nov 2009 02:27:50 +0000 (21:27 -0500)]
make <Enter> from search screen display the correct message

11 years agoupdated README
Bart Trojanowski [Thu, 19 Nov 2009 02:18:24 +0000 (21:18 -0500)]
updated README

11 years agoadd 's' binding to let you search for different terms
Bart Trojanowski [Thu, 19 Nov 2009 02:13:46 +0000 (21:13 -0500)]
add 's' binding to let you search for different terms

11 years agoreverse order so that the latest is at top
Bart Trojanowski [Thu, 19 Nov 2009 02:13:24 +0000 (21:13 -0500)]
reverse order so that the latest is at top

11 years agoREADME
Bart Trojanowski [Thu, 19 Nov 2009 02:03:51 +0000 (21:03 -0500)]
README

11 years agosimplify install with a Makefile
Bart Trojanowski [Thu, 19 Nov 2009 02:00:56 +0000 (21:00 -0500)]
simplify install with a Makefile

11 years agoadded syntax files for search and show screens
Bart Trojanowski [Thu, 19 Nov 2009 02:00:43 +0000 (21:00 -0500)]
added syntax files for search and show screens

11 years agomove from search to show with Enter, and back with q
Bart Trojanowski [Thu, 19 Nov 2009 02:00:17 +0000 (21:00 -0500)]
move from search to show with Enter, and back with q

11 years agoprimitive notmuch mail interface for vim
Bart Trojanowski [Wed, 18 Nov 2009 21:43:42 +0000 (16:43 -0500)]
primitive notmuch mail interface for vim

11 years agonotmuch.el: Quote arguments to protect from shell interpretation.
Carl Worth [Wed, 25 Nov 2009 03:08:53 +0000 (19:08 -0800)]
notmuch.el: Quote arguments to protect from shell interpretation.

We want to allow the user to be able to use search expressions with
parentheses and semi-colons, etc. and we definitely don't want the
shell interpreting those!

11 years agonotmuch.el: Exceute "notmuch search" asynchronously.
Carl Worth [Wed, 25 Nov 2009 02:49:58 +0000 (18:49 -0800)]
notmuch.el: Exceute "notmuch search" asynchronously.

Previously, our emacs interface was waiting for the "notmuch search"
to complete before it would display anything. Now, we execute the
process asyncrhonously and filter results as they come in.

This takes advantage of the recent work to make "notmuch search"
results stream out steadily. The result is that some search results
will be available nearly instantly and the user can navigate and view
those while additional results continue loading.

11 years agoMerge buttons-for-body-and-headers branch.
Carl Worth [Tue, 24 Nov 2009 19:35:08 +0000 (11:35 -0800)]
Merge buttons-for-body-and-headers branch.

Thanks, Alexander!

11 years agoRemove the global expand body keymapping
Alexander Botero-Lowry [Tue, 24 Nov 2009 07:41:42 +0000 (23:41 -0800)]
Remove the global expand body keymapping

With local buttons done now, we don't need this anymore.

11 years agolib/messages.c: Make message searches stream as well.
Carl Worth [Tue, 24 Nov 2009 05:47:24 +0000 (21:47 -0800)]
lib/messages.c: Make message searches stream as well.

Xapian provides an interator-based interface to all search results.
So it was natural to make notmuch_messages_t be iterator-based as
well. Which we did originally.

But we ran into a problem when we added two APIs, (_get_replies and
_get_toplevel_messages), that want to return a messages iterator
that's *not* based on a Xapian search result. My original compromise
was to use notmuch_message_list_t as the basis for all returned
messages iterators in the public interface.

This had the problem of introducing extra latency at the beginning
of a search for messages, (the call would block while iterating over
all results from Xapian, converting to a message list).

In this commit, we remove that initial conversion and instead provide
two alternate implementations of notmuch_messages_t (one on top of a
Xapian iterator and one on top of a message list).

With this change, I tested a "notmuch search" returning *many* results
as previously taking about 7 seconds before results started appearing,
and now taking only 2 seconds.

11 years agoMake bodies locally toggleable
Alexander Botero-Lowry [Tue, 24 Nov 2009 07:39:57 +0000 (23:39 -0800)]
Make bodies locally toggleable

Having actually implemented this, I realized that my
initial approach of providing a function to configure
a button was wrong. Instead I've replaced that with
button types. This then makes it possible to provide
the fully expanded view when all threads in a message
are unread.

It also has the potential to allow global-expansion functions
if that is desireable

11 years agomake a nice function for generating invisibility toggle buttons
Alexander Botero-Lowry [Tue, 24 Nov 2009 06:37:49 +0000 (22:37 -0800)]
make a nice function for generating invisibility toggle buttons

I realized I was replicating this code over and over again, so this
way if I change my mind about something I only have to do it on one
place.

11 years agocleanup a lot of left-overs from the global invis
Alexander Botero-Lowry [Tue, 24 Nov 2009 06:28:56 +0000 (22:28 -0800)]
cleanup a lot of left-overs from the global invis

Basically I'd left in a lot of the key-bindings and all the
invisiblity spec variables so just rid the world of those

11 years agomake headers locally expandable/collapsable
Alexander Botero-Lowry [Tue, 24 Nov 2009 06:25:33 +0000 (22:25 -0800)]
make headers locally expandable/collapsable

This is the same as with citations and signatures.
I used an ellipsis here for the invisible region, which
I think make it more obvious that there are extra headers.
MH-e used this for extra long To/CC headers.

11 years agolib/query: Drop the first and max_messages arguments from search_messages.
Carl Worth [Tue, 24 Nov 2009 04:25:13 +0000 (20:25 -0800)]
lib/query: Drop the first and max_messages arguments from search_messages.

These only existed to support the chunky-searching hack, but that
was recently dropped anyway.

11 years agolib/query: Fix notmuch_threads_t to stream results rather than blocking.
Carl Worth [Tue, 24 Nov 2009 04:18:57 +0000 (20:18 -0800)]
lib/query: Fix notmuch_threads_t to stream results rather than blocking.

Previously, notmuch_query_search_threads would do all the work, so the
caller would block until all results were processed. Now, we do the
work as we go, as the caller iterates with notmuch_threads_next. This
means that once results start coming back from "notmuch search" they
just keep continually streaming.

There's still some initial blocking before the first results appear
because the notmuch_messages_t object has the same bug (for now).

11 years agonotmuch search: Remove the chunked-searching hack.
Carl Worth [Tue, 24 Nov 2009 04:12:57 +0000 (20:12 -0800)]
notmuch search: Remove the chunked-searching hack.

This was a poor workaround around the fact that the existing
notmuch_threads_t object is implemented poorly. It's got a fine
iterartor-based interface, but the implementation does all of the
work up-front in _create rather than doing the work incrementally
while iterating.

So to start fixing this, first get rid of all the hacks we had working
around this. This drops the --first and --max-threads options from the
search command, (but hopefully nobody was using them
anyway---notmuch.el certainly wasn't).

11 years agonotmuch.el: Add TAB and M-TAB buttons to move between buttons.
Carl Worth [Tue, 24 Nov 2009 03:03:59 +0000 (19:03 -0800)]
notmuch.el: Add TAB and M-TAB buttons to move between buttons.

Thanks to Alexander Botero-Lowry for pointing out the interesting
functions to use here. This functionality was really easy to add.

11 years agoFix printing of literal '%' in help message.
Carl Worth [Tue, 24 Nov 2009 02:36:14 +0000 (18:36 -0800)]
Fix printing of literal '%' in help message.

I suppose I could have just used puts instead...

11 years agoMake addresses case insensitive for the purpose of constructing replies.
Jed Brown [Mon, 23 Nov 2009 18:29:52 +0000 (19:29 +0100)]
Make addresses case insensitive for the purpose of constructing replies.

The domain is alway case insensitive, but in principle the username is
case sensitive.  Few systems actually enforce this so I think a good
default is to treat the entire address as case insensitive, it will
eliminate a lot of superfluous self-addressed messages and reply from
the correct address in these cases.

Signed-off-by: Jed Brown <jed@59A2.org>
11 years agoStay out of tmp to respect the Maildir spec.
Jed Brown [Mon, 23 Nov 2009 20:57:33 +0000 (21:57 +0100)]
Stay out of tmp to respect the Maildir spec.

11 years agosearch : Extend "intial burst" optimization to return all results by chunks
Carl Worth [Mon, 23 Nov 2009 16:42:45 +0000 (17:42 +0100)]
search : Extend "intial burst" optimization to return all results by chunks

This way, the user gets a steady (but bursty) stream of reults. We
double the chunk size each time since each successive chunk has to
redo work from all previous chunks.

Of course, the overall time is thereby slower, as the price we pay for
increased responsiveness. With a search returning about 17000 thread
results I measured a total time of 48.8 seconds before this change and
58.4 seconds afterwards.

11 years agoAdd rudimentary date-based search.
Carl Worth [Mon, 23 Nov 2009 15:58:35 +0000 (16:58 +0100)]
Add rudimentary date-based search.

The rudimentary aspect here is that the date ranges are specified with
UNIX timestamp values (number of seconds since 1970-01-01 UTC). One
thing that can help here is using the date program to determins
timestamps, such as:

$(date +%s -d 2009-10-01)..$(date +%s)

Long-term, we'll probably need to do our own query parsing to be able
to support directly-specified dates and also relative expressions like
"since:'2 months ago'".

11 years agoAdd notmuch-folder mode to provide an overview of search matches
Keith Packard [Sat, 21 Nov 2009 19:59:00 +0000 (11:59 -0800)]
Add notmuch-folder mode to provide an overview of search matches

Folder mode takes a (user-configurable) list of search patterns and
produces a list of those patterns and the count of messages that they
match. When an entry in this list is selected, a search window with
the defined search is opened.  The set of folders is defined as a
list, each element contains the name of the folder and the query string
to count.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 years agoAdd 'notmuch count' command to show the count of matching messages
Keith Packard [Sat, 21 Nov 2009 07:15:07 +0000 (23:15 -0800)]
Add 'notmuch count' command to show the count of matching messages

Getting the count of matching threads or messages is a fairly
expensive operation. Xapian provides a very efficient mechanism that
returns an approximate value, so use that for this new command.

This returns the number of matching messages, not threads, as that is
cheap to compute.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 years agoMake mouse-1 click in search view show thread
Keith Packard [Sat, 21 Nov 2009 07:15:06 +0000 (23:15 -0800)]
Make mouse-1 click in search view show thread

Selecting text in the search view isn't all that useful, so instead,
make mouse-1 clicks actually show the thread you click on. It's almost
like direct manipulation or something.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 years agoTODO: Yet another idea.
Carl Worth [Mon, 23 Nov 2009 05:28:41 +0000 (06:28 +0100)]
TODO: Yet another idea.

This is an idea I've had "forever" (and is commented as such in the
code already), but just came up on the mailing list. So note it here.

11 years agoANSI escapes in "new" only when output is a tty
Adrian Perez [Mon, 23 Nov 2009 00:54:35 +0000 (01:54 +0100)]
ANSI escapes in "new" only when output is a tty

When running "notmuch new --verbose", ANSI escapes are used. This may not be
desirable when the output of the command is *not* being sent to a terminal
(e.g. when piping output into another command). In that case each file
processed is printed in a new line and ANSI escapes are not used at all.

11 years agofix notmuch-new bug when database path ends with a trailing /
Bart Trojanowski [Sun, 22 Nov 2009 16:19:31 +0000 (11:19 -0500)]
fix notmuch-new bug when database path ends with a trailing /

I configured my database.path with a trailing /, and after running notmuch
new every notmuch search would fail with error messages like this:

  Error opening /inbox/cur/1258565257.000211.mbox:2,S: No such file or directory

The actual bug was in the filename normalization for storage in the
database.  The database.path was removed from the full filename, but if
the database.path from the config file contained a trailing /, the
relative file name would retain an extra leading /... which made it look
like an absolute path after it was read out from the DB.

Signed-off-by: Bart Trojanowski <bart@jukie.net>
11 years agoTODO: Add a couple of notes about things to do with/to Xapian.
Carl Worth [Mon, 23 Nov 2009 02:48:04 +0000 (03:48 +0100)]
TODO: Add a couple of notes about things to do with/to Xapian.

I had these notes sitting in an uncommitted file that was cluttering
up my "git status" output. This cleans that up, and also shares the
ideas with the wider community.

11 years agomakefile: Declare clean target as phony.
Jan Janak [Sun, 22 Nov 2009 12:55:35 +0000 (13:55 +0100)]
makefile: Declare clean target as phony.

This ensures that make clean always proceeds, even if the user
accidentally creates a file named 'clean'. Also, it ignores errors in
rm and other commands.

Signed-off-by: Jan Janak <jan@ryngle.com>
11 years agoTODO: Capturing even more ideas.
Carl Worth [Mon, 23 Nov 2009 02:34:24 +0000 (03:34 +0100)]
TODO: Capturing even more ideas.

Hopefully soon I can start implementing ideas rather than just writing
them down.

11 years agoTODO: A couple of more ideas for improving the emacs interface.
Carl Worth [Mon, 23 Nov 2009 02:04:16 +0000 (03:04 +0100)]
TODO: A couple of more ideas for improving the emacs interface.

We're not likely to run out of work to do anytime soon...

11 years agoSupport multiple configuration files via $NOTMUCH_CONFIG
Alec Berryman [Sun, 22 Nov 2009 05:18:26 +0000 (23:18 -0600)]
Support multiple configuration files via $NOTMUCH_CONFIG

If present, $NOTMUCH_CONFIG will be used as the configuration file
location.

11 years agoTODO: Add several ideas for improving the emacs interface.
Carl Worth [Mon, 23 Nov 2009 01:57:39 +0000 (02:57 +0100)]
TODO: Add several ideas for improving the emacs interface.

These are from email messages on the notmuch mailing list and from
IRC conversations in #notmuch.

11 years agoInsert signature into replies
Keith Packard [Sat, 21 Nov 2009 04:57:35 +0000 (20:57 -0800)]
Insert signature into replies

When you compose a new message, message mode carefully inserts your
mail signature at the bottom of the message; as notmuch constructs the
reply all by itself, this doesn't happen then. Use the message mode
function 'message-insert-signature' to add that to reply buffers.

Signed-off-by: Keith Packard <keithp@keithp.com>
11 years agoQuote file names passed to the shell
Jed Brown [Sat, 21 Nov 2009 02:37:54 +0000 (03:37 +0100)]
Quote file names passed to the shell

Prior to this, notmuch-show-pipe-message could not handle file names
with spaces and similar.

11 years agoSupport for printing file paths in new command
Adrian Perez [Sat, 21 Nov 2009 00:17:18 +0000 (01:17 +0100)]
Support for printing file paths in new command

For very large mail boxes, it is desirable to know which files are being
processed e.g. when a crash occurs to know which one was the cause. Also,
it may be interesting to have a better idea of how the operation is
progressing when processing mailboxes with big messages.

This patch adds support for printing messages as they are processed by
"notmuch new":

* The "new" command now supports a "--verbose" flag.

* When running in verbose mode, the file path of the message about to be
  processed is printed in the following format:

    current/total: /path/to/message/file

  Where "current" is the number of messages processed so far and "total" is
  the total count of files to be processed.

  The status line is erased using an ANSI sequence "\033[K" (erase current
  line from the cursor to the end of line) each time it is refreshed. This
  should not pose a problem because nearly every terminal supports it.

* The signal handler for SIGALRM and the timer are not enabled when running
  in verbose mode, because we are already printing progress with each file,
  periodical reports are not neccessary.

11 years agoMerge remote branch 'drax/master'
Carl Worth [Sun, 22 Nov 2009 23:43:26 +0000 (00:43 +0100)]
Merge remote branch 'drax/master'

11 years agoswitch to button-1, which seems to interact poorly with text-selection by mouse
Alexander Botero-Lowry [Sun, 22 Nov 2009 23:42:59 +0000 (15:42 -0800)]
switch to button-1, which seems to interact poorly with text-selection by mouse

11 years agoTODO: Add a bunch of ideas that have been on my mind lately.
Carl Worth [Sun, 22 Nov 2009 23:29:00 +0000 (00:29 +0100)]
TODO: Add a bunch of ideas that have been on my mind lately.

So get these out of my mind and out to the user community.

11 years agoinstead of trying to cause a redisplay, actually do a redisplay
Alexander Botero-Lowry [Sun, 22 Nov 2009 23:24:25 +0000 (15:24 -0800)]
instead of trying to cause a redisplay, actually do a redisplay