Commit graph

2689 commits

Author SHA1 Message Date
David Bremner
ffce9b7c25 NEWS: set release date.
It's Friday the thirteenth. What could possibly go wrong?
2012-01-13 20:28:44 -04:00
David Bremner
307a2e3fa2 debian: changelog stanza for 0.11 2012-01-13 20:06:39 -04:00
David Bremner
9ada8335c6 Update version to 0.11 2012-01-13 19:58:36 -04:00
David Edmondson
38546e4acb emacs: Improve `notmuch-hello' display on ttys.
Inserting spaces to pad out columns is good, except when the padding
makes the line wider than the window. This looks particularly bad on a
tty where there is no fringe.

Hence, avoid padding the last column on each row.
2012-01-12 22:33:29 -04:00
Jani Nikula
3f9d73884e lib: fix messages.c build warn
lib/messages.c: In function ‘notmuch_messages_move_to_next’:
lib/messages.c:131:2: warning: ISO C forbids ‘return’ with expression, in function returning void [-pedantic]

Signed-off-by: Jani Nikula <jani@nikula.org>
2012-01-10 06:33:23 -04:00
Jani Nikula
949fd801f8 man: add missing SEE ALSO header to notmuch reply man page
Signed-off-by: Jani Nikula <jani@nikula.org>
2012-01-10 06:33:01 -04:00
David Edmondson
03146f2013 emacs: Mark the quoted region during reply.
Mark the quoted region of text during a reply, making it easy for the
user to delete it quickly.
2012-01-10 06:31:02 -04:00
David Edmondson
a74ec0edd6 emacs: Better handling of inherited keymaps for `nomuch-help'.
`notmuch-hello-mode' inherits the keymap for widgets, which confused
`notmuch-substitute-command-keys'. Fix the confusion.

Simplify `notmuch-substitute-command-keys' a little to make it easier
to read.
2012-01-09 22:33:19 -04:00
Jani Nikula
fb846f57ef NEWS: add news entry for notmuch reply uninitialized variable bugfix 2012-01-09 22:12:24 -04:00
Sebastian Spaeth
980daa26b5 Merge branch 'master' of ssh://notmuchmail.org/git/notmuch 2012-01-09 17:25:19 +01:00
David Bremner
d3a74bb0a0 debian: add changelog stanza for 0.11~rc3-1
as usual for pre-releases, fairly minimal commentary.
2012-01-09 07:13:56 -04:00
David Bremner
310608f279 version: update to 0.11~rc3
We found another serious-ish bug during freeze.
2012-01-09 07:05:40 -04:00
Jani Nikula
80ae1829c1 cli: fix use of uninitialized variable in "notmuch reply"
notmuch_show_params_t params is only initialized partially in
notmuch_reply_command(). The only field that is used uninitialized is
params.decrypt. It is usually non-zero, making "notmuch reply" on encrypted
messages work by coincidence.

Initialize params properly, and set params.decrypt as needed.

Signed-off-by: Jani Nikula <jani@nikula.org>
2012-01-09 06:50:20 -04:00
Jani Nikula
2d1385e141 cli: convert "notmuch reply" to use the new argument parser
Use the new notmuch argument parser to handle arguments in "notmuch
reply". There should be no functional changes.

Signed-off-by: Jani Nikula <jani@nikula.org>
2012-01-09 06:45:02 -04:00
Jani Nikula
230c2ed357 cli: fix use of uninitialized variable in "notmuch reply"
notmuch_show_params_t params is only initialized partially in
notmuch_reply_command(). The only field that is used uninitialized is
params.decrypt. It is usually non-zero, making "notmuch reply" on encrypted
messages work by coincidence.

Initialize params properly, and set params.decrypt as needed.

Signed-off-by: Jani Nikula <jani@nikula.org>
2012-01-09 06:44:47 -04:00
David Edmondson
dd41a07bbd emacs: Don't signal an error when reaching the end of the search results.
With the default configuration ('space' moves through the messages
matching the search and back to the results index at the end) it's
unnecessary to signal an error when the last message has been read, as
this is the common case.

Moreover, it's very annoying when `debug-on-error' is t.
2012-01-09 06:40:24 -04:00
Patrick Totzke
ab69d6efa0 python test "compare message ids"
Introduces a second (trivial) test for the python
bindings that searches for message ids and compares
the output with that of `notmuch search`.
2012-01-08 13:46:50 +01:00
Patrick Totzke
aadf202dd5 clean up "compare thread ids" python test
This makes the test script open the database in READ_ONLY mode
and use the libraries own sorting methods instead of "sort".
2012-01-08 13:46:25 +01:00
Thomas Jost
e0991930c0 Update NEWS for Emacs changes
- A fair amount of conflict resolution by db.
2012-01-05 17:56:33 -04:00
David Bremner
9981f995c6 NEWS: give a hint about using sort to achieve the old dump behavior.
This is needed for a few applications, and actually is quite
fast (relative to the actual dump).
2012-01-05 17:52:50 -04:00
David Bremner
84d9e319ad NEWS: fix typos.
Thanks to Xavier for one of these.
2012-01-05 17:52:07 -04:00
Jameson Graef Rollins
4bda23f160 update NEWS
This change looks slightly larger than it actually is, since I moved
the emacs section below the Performance and Memory Management
sections.
2012-01-05 17:49:05 -04:00
Jameson Graef Rollins
74bced62b4 emacs: fix notmuch-show-indent-messages-width customization variable name
The name was originally notmuch-indent-messages-width, which is
inconsistent with our variable naming convention.
2012-01-05 17:48:46 -04:00
Sebastian Spaeth
228d8c0528 python: str.decode() doesn't like kwargs in python 2.5
Recent changes introduced lots of unicodification of strings, mostly in
the form of .decode('utf-8', errors='ignore'). However, python 2.5 does
not like the errors keyword argument and complains. It does work when
used as a simple arg though, so that's what this patch does.

Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2012-01-02 17:07:53 +01:00
Justus Winter
ada246aa20 python: make the result of Message.get_replies() more pythonic
Formerly Message.get_replies() returned an iterator or None forcing
users to check the result before iterating over it leading to strange
looking code at the call site.

Fix this flaw by adding an EmptyMessagesResult class that behaves like
the Messages class but immediatly raises StopIteration if used as an
iterator and returning objects of this type from Message.get_replies()
to indicate that there are no replies.
2012-01-02 17:01:40 +01:00
Justus Winter
e32c8a5e6b python: refactor print_messages into format_messages and print_messages 2012-01-02 16:55:53 +01:00
Justus Winter
83b256b12b python: add missing conversions from and to utf-8 2012-01-02 16:34:56 +01:00
Justus Winter
4a6642a2a1 py3k: Add and use a mixin class that implements __str__
Amended by Sebastian Spaeth <Sebastian@SSpaeth.de> to include the
required sys import in globals.py.
2012-01-02 16:33:29 +01:00
Justus Winter
26d52cf6cf py3k: Rename .next() to __next__(), add python2.x compatibility alias 2012-01-02 16:12:28 +01:00
Justus Winter
9c32ee5372 py3k: All strings are unicode strings in py3k 2012-01-02 16:11:52 +01:00
Justus Winter
4ed0362d41 py3k: The ConfigParser module has been renamed to configparser 2012-01-02 16:08:32 +01:00
Justus Winter
676ce952d3 py3k: The execfile built-in has been removed in python 3 2012-01-02 16:06:59 +01:00
David Bremner
4f5b71c38d debian: changelog stanza for 0.11~rc2-1
Set dist=experimental the first time.
2012-01-02 07:08:24 -04:00
David Bremner
ec27f802cd debian: fix typo in changelog
Previous version was actually uploaded to experimental, not unstable
2012-01-02 07:08:07 -04:00
David Bremner
ff58a06e83 version: bump to 0.11~rc2
This to "celebrate" pushing a bugfix in at the last minute.
2012-01-02 06:50:07 -04:00
Kazuo Teramoto
f80d4f9f6d lib: call g_mime_init() from notmuch_database_open()
As reported in
id:"CAEbOPGyuHnz4BPtDutnTPUHcP3eYcRCRkXhYoJR43RUMw671+g@mail.gmail.com"
sometimes gmime tries to access a NULL pointer, e.g. g_mime_iconv_open()
tries to access iconv_cache that is NULL if g_mime_init() is not called.
This causes notmuch to segfault when calling gmime functions.

Calling g_mime_init() initializes iconv_cache and others variables needed
by gmime, making sure they are initialized when notmuch calls gmime
functions.
2012-01-02 06:50:07 -04:00
Kazuo Teramoto
442d405ad3 lib: call g_mime_init() from notmuch_database_open()
As reported in
id:"CAEbOPGyuHnz4BPtDutnTPUHcP3eYcRCRkXhYoJR43RUMw671+g@mail.gmail.com"
sometimes gmime tries to access a NULL pointer, e.g. g_mime_iconv_open()
tries to access iconv_cache that is NULL if g_mime_init() is not called.
This causes notmuch to segfault when calling gmime functions.

Calling g_mime_init() initializes iconv_cache and others variables needed
by gmime, making sure they are initialized when notmuch calls gmime
functions.

Test marked fix by db.
2011-12-31 23:08:15 -04:00
David Bremner
7da6733e89 test: add two new messages to corpus with iso-8859-1 encoding
One is quoted printable, the other users 8 bit encoding. The latter
triggers a bug in the python bindings due to missing call to
g_mime_init. The corresponding test is marked broken in this commit.
2011-12-31 23:04:01 -04:00
David Bremner
bebf80ea68 test: use file based comparison for search '*' test
This seems a bit easier to maintain, and is more accurate since lines
are not joined together.
2011-12-31 22:59:58 -04:00
David Bremner
07768fb1bb notmuch: replace built-in help with exec of man
"notmuch help" now relies on a working man installation, and a correct
setting of MANPATH, for users that install in "unusual" places. This
should probably noted in NEWS before shipping.

There is still some small duplication of docs as the one line
summaries are hard coded in the binary. This seems preferable to
complicated script games, at least as long was we are using a
presentation level markup like nroff.
2011-12-31 15:16:32 -04:00
Jameson Graef Rollins
f3d800124f force install notmuch-setup.1 symlink
This will prevent the install from failing if the link already exists.
2011-12-31 15:16:32 -04:00
Jameson Graef Rollins
f079f5f931 break up dump and restore man pages.
These functions are enough different in their behavior that it's not
really worth it to combine them.  They overlap in the format of the
dump file, but we can have a separate page that describes the dump
format, and either reference it or include it.  This also keeps things
nice and clean with one page per command.
2011-12-31 15:16:32 -04:00
Jameson Graef Rollins
77b8d70600 remove reference to notmuch-part.1 from Makefile.local 2011-12-31 15:16:32 -04:00
David Bremner
3fd1f0e062 debian: install split man pages.
We now have man pages in sections 5 and 7 as well, so we copy the
whole /usr/share/man hierarchy.
2011-12-31 15:16:32 -04:00
David Bremner
af12e5a3ac build-system: update for split man pages
- We have to remove the installation of notmuch.1.gz from the top
level Makefile.local.

- Man pages with multiple names are handled by making relative
  symlinks in the install-man target.

- update version tests and convenience rules for split man pages

  The man page version test still only checks notmuch.1, but the
  location is updated.

  update-man-versions is longer than the one-line previously in
  update-versions mainly because I decided to take the high road and
  stick to POSIX sed (thus, no sed -i). The sed regex itself is more
  complicated to cope with variations in the headers.
2011-12-31 15:16:32 -04:00
David Bremner
7c5695b439 man/*: fixup page references
- Replace references to section X below with page refences.

- Add SEE ALSO to each page.  This is a bit error prone, because each
  SEE ALSO section is different, i.e. a page does not refer to itself.
2011-12-31 15:16:32 -04:00
David Bremner
5d13210a09 notmuch-config.1: fix typo 2011-12-31 15:16:32 -04:00
David Bremner
8026b4a9ff notmuch.1: smooth wording.
After most of the content was ripped out of the page, a few words were
needed to glue things back togetehr.
2011-12-31 15:16:32 -04:00
David Bremner
482033f8f8 man/*: formatting cleanup
Fix some problems with indentation (controlled by markup) and
whitespace.

- notmuch.1: reformat

  Use .SS macro to make "notmuch setup" a subsection. Introduce another
  subsection for the remaining commands.

- notmuch-config.1: reformat

   Put all the syntax in the synopsis. Supposedly this is the the UNIX way.

- notmuch-reply.1: fix formatting issues.

  Give nicer formatting for synopsis.

  Insert missing SEE ALSO header.

- notmuch-dump.1: reformat using subsections

  These seems more natural, although, as mentioned, it does require
  referring back to the synopsis. Or maybe copying parts of the
  synopsis
2011-12-31 15:16:32 -04:00
David Bremner
2d68f4ca9b man: add symlinks for notmuch-restore.1 and notmuch-setup.1
These are just for the convenience of testers using $src/man as an
element of MANPATH. They are intentionally omitted from MAN1, so that
they do not interfere with the install.
2011-12-31 15:16:31 -04:00