aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2011-12-08test: tests for command-line-arguments.cDavid Bremner
This was needed because no current notmuch code exercises the NOTMUCH_OPT_STRING style arguments.
2011-12-08command-line-arguments.[ch]: new argument parsing framework for notmuch.David Bremner
As we noticed when Jani kindly converted things to getopt_long, much of the work in argument parsing in notmuch is due to the the key-value style arguments like --format=(raw|json|text). The framework here provides positional arguments, simple switches, and --key=value style arguments that can take a value being an integer, a string, or one of a set of keywords.
2011-12-07json: date_relative for threadspazz
include the date_relative field in the json formated output of notmuch search
2011-12-07test: date_relative in notmuch search json outputpazz
expect the date_relative field for thread entries in notmuch search's json output note from Commiter: we don't have to worry about the date changing because the date in question is more than 180 days old.
2011-12-07emacs: do not call notmuch show for non-inlinable partsDmitry Kurochkin
Before the change, there was a workaround to avoid notmuch show calls for parts with application/* Content-Type. But non-inlinable parts are not limited to this Content-Type (e.g. mp3 files have audio/mpeg Content-Type and are not inlinable). For such parts `notmuch-show-insert-part-*/*' handler is called which unconditionally fetches contents for all parts. The patch moves content fetching from `notmuch-show-insert-part-*/*' to `notmuch-show-mm-display-part-inline' function after MIME inlinable checks are done to avoid useless notmuch show calls. The application/* hack is no longer needed and removed.
2011-12-07test: check that Emacs UI does not call notmuch for non-inlinable partsDmitry Kurochkin
The patch adds two new test cases: * Do not call notmuch for non-inlinable application/mpeg parts * Do not call notmuch for non-inlinable audio/mpeg parts The application/mpeg test passes thanks to a workaround for application/* Content-Types. The audio/mpeg is currently broken.
2011-12-07test: add functions to count how much times notmuch was calledDmitry Kurochkin
The patch adds two auxiliary functions and a variable: notmuch_counter_reset $notmuch_counter_command notmuch_counter_value They allow to count how many times notmuch binary is called. notmuch_counter_reset() function generates a script that counts how many times it is called and resets the counter to zero. The function sets $notmuch_counter_command variable to the path to the generated script that should be called instead of notmuch to do the counting. The notmuch_counter_value() function returns the current counter value.
2011-12-07emacs: remove unused variable in `notmuch-show-insert-part-message/rfc822'Dmitry Kurochkin
An obvious cleanup. I wonder why there was no warning about this during compilation.
2011-12-07emacs: remove some code duplication in notmuch-showDmitry Kurochkin
Add optional props argument to `notmuch-show-get-header'. Use it to get headers in `notmuch-show-insert-part-multipart/signed' and `notmuch-show-insert-part-multipart/encrypted'.
2011-12-07test/symbol-hiding: compare exported symbols with existing oneDavid Bremner
We assume that any symbol starting with notmuch_ in lib/*.o should be exported, and that only those symbols should be exported.
2011-12-07test/symbol-hiding: add some whitespace between testsDavid Bremner
This is in preparation for adding a third test to this file
2011-12-06Merge branch 'release'David Bremner
Conflicts: NEWS Conflicts resolved by inserting the 0.10.2 stanza before 0.11
2011-12-06fix format string in Message.__unicode__Patrick Totzke
Since 2b0116119160f2dc83, Message.__str__ doesn't construct a hash containing the thread data before constructing the formatstring. This changes the formatstring to accept positional parameters instead of a hash.
2011-12-06contrib/.gitattributes: removeDavid Bremner
Now that licensing of notmuch-deliver has been harmonized with notmuch, there is no reason not to export it.
2011-12-06notmuch-deliver: GPL-3+Ali Polatel
2011-12-06notmuch-deliver: Import from maildrop-2.5.5Ali Polatel
maildrop-2.5.5 is GPL-3. No change in functionality, just a precaution before relicensing.
2011-12-06make release: remove LATEST-$(PACKAGE)-*Tomi Ollila
The tar file of particular package (notmuch in this case) is named as $(PACKAGE)-$(VERSION).tar.gz. Therefore the best way to remove previous link to LATEST is to remove all files beginning with LATEST-$(PACKAGE)- and not relying how $(VERSION) string is constructed.
2011-12-06have LATEST-notmuch-<version>.tar.gz on releases web pageTomi Ollila
The notmuchmail/releases page used to have LATEST-notmuch-<version> to link to the latest notmuch source tarball. This is confusing on web page and on disk when the file has been downloaded. This change looks a bit inconsistent with the 'rm' command just executed before. $(TAR_FILE) is defined (currently) as $(PACKAGE)-$(VERSION).tar.gz; as long as the prefix stays $(PACKAGE)-$(VERSION) and version begins with a digit then this line is good in execution point of view.
2011-12-06test: add test-binaries targetDavid Bremner
The goal here is to have a simple way of making sure all of the binaries needed to run tests are available.
2011-12-06python: Remove stray debug commentSebastian Spaeth
This slipped in wrongly in commit 71e0082eff (due to my fault). Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2011-12-06python: use wrapped notmuch_*_t types instead of raw pointersThomas Jost
Now that types are checked correctly, we also need to make sure that all the arguments actually are instances of these types. Otherwise the function calls will fail and raise an exception similar to this one: ctypes.ArgumentError: argument 3: <type 'exceptions.TypeError'>: expected LP_LP_NotmuchMessageS instance instead of pointer to c_void_p
2011-12-06errors='ignore' when decode to unicodePatrick Totzke
2011-12-06use __unicode__ for string representationPatrick Totzke
2011-12-06clean up Thread.__str__Patrick Totzke
2011-12-06python: Return a STATUS value in tags_to_flags and flags_to_tagsSebastian Spaeth
We were not returning anything at all, which does not match the API documentation. Fixed. Thanks to Patrick Totzke for the heads up. Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
2011-12-06remove unused importsPatrick Totzke
2011-12-06fix sphinx compile-time warningsPatrick Totzke
no changes to the code, only makes compiling the docs smoother as some rsT syntax errors were fixed
2011-12-06pep8 fixesPatrick Totzke
no changes to the code, only fixed stuff denounced by `pep8 *py`
2011-12-05test/python: set LD_LIBRARY_PATH and PYTHONPATH to use local notmuchdebian/0.10.2-10.10.2David Bremner
Possibly this should be factored out into some kind of "run_python" function.
2011-12-05build system: allow decreasing debian versions for debian-snapshotDavid Bremner
This allows the debian-snapshot to continue working between when debian/changelog is updated and when the release is tagged.
2011-12-05NEWS: add news for 0.10.2David Bremner
2011-12-05fixup for changelogDavid Bremner
2011-12-05debian/changelog: add new changelog stanza for 0.10.2David Bremner
2011-12-05version: bump for bugfix release 0.10.2David Bremner
2011-12-05test: add tests for python bindingsDavid Bremner
We start modestly, with a (slightly modified) test case from Kazuo Teramoto. Originally it just made sure the bindings didn't crash; here we check that by comparing the output with that of notmuch search.
2011-12-04lib: call g_type_init from notmuch_database_openDavid Bremner
We want to make sure g_type_init is called before any GObject functionality is used.
2011-12-04notmuch-dump.c: whitespace cleanupDavid Bremner
2011-12-01python: annotate all calls into libnotmuch with typesJustus Winter
Add type information to the ctypes._FuncPtr wrappers and use the wrapper classes instead of c_void_p for pointers to notmuch_*_t. This enables the ctypes library to type check parameters being handed to functions from the notmuch library. Signed-off-by: Justus Winter <4winter@informatik.uni-hamburg.de>
2011-12-01python: add classes to wrap all notmuch_*_t typesJustus Winter
Signed-off-by: Justus Winter <4winter@informatik.uni-hamburg.de>
2011-11-30test: fix error messages for missing binary dependenciesDmitry Kurochkin
The fake missing binary functions check if the binary has already be added to the diagnostic message to avoid duplicates. Unfortunately, this check was buggy because the message string does not have the trailing space.
2011-11-30test: fix spurious output from missing external binaries functionsDmitry Kurochkin
The grep(1) command used in the fake binary functions was missing the quiet option.
2011-11-30test: add missing escape backslash in test_declare_external_prereq()Dmitry Kurochkin
2011-11-30test: fix test_require_external_prereq()Dmitry Kurochkin
test_missing_external_prereq_${binary}_ variable indicates that the binary is missing. It must be set in test_declare_external_prereq() outside of the fake $binary() function.
2011-11-30emacs: Use notmuch-command variable in process-lines.Chris Gray
The process-lines function calls the notmuch binary. The location of the binary may have been customized by the user, so it is better to use the customized location rather than allowing the process-lines function to search the user's PATH for the binary.
2011-11-28dump: Don't sort the output by message id.Thomas Schwinge
Asking xapian to sort the messages for us causes suboptimal IO patterns. This would be useful, if we only wanted the first few results, but since we want everything anyway, this is pessimization. On 2011-10-29, a measurement on a 372981 messages instance showed that wall time can be reduced from 28 minutes (sorted by Message-ID) to 15 minutes (unsorted). Timings on 189605 messages: $ time notmuch.old dump 19.48user 5.83system 12:10.42elapsed 3%CPU (0avgtext+0avgdata 110656maxresident)k 3629584inputs+22720outputs (33major+7073minor)pagefaults 0swaps $ echo 3 > /proc/sys/vm/drop_caches $ time notmuch.new 14.89user 1.20system 3:23.58elapsed 7%CPU (0avgtext+0avgdata 46032maxresident)k 1256264inputs+22464outputs (43major+1990minor)pagefaults 0swaps
2011-11-28tag: Automatically limit to messages whose tags will actually change.Austin Clements
This optimizes the user's tagging query to exclude messages that won't be affected by the tagging operation, saving computation and IO for redundant tagging operations. For example, notmuch tag +notmuch to:notmuch@notmuchmail.org will now use the query ( to:notmuch@notmuchmail.org ) and (not tag:"notmuch") In the past, we've often suggested that people do this exact transformation by hand for slow tagging operations. This makes that unnecessary.
2011-11-27test: fix "Stashing in notmuch-search" test when emacs is not availableDmitry Kurochkin
If emacs is not available, test_expect_equal would be called with only one argument. The patch fixes this by quoting the (possibly empty) $(cat OUTPUT) argument.
2011-11-27test: check if emacs is available in the beginning of test_emacsDmitry Kurochkin
Unfortunately, this is needed to avoid the emacs waiting loop.
2011-11-27test: add function to explicitly check for external dependenciesDmitry Kurochkin
Useful when binary is called indirectly (e.g. from emacs).
2011-11-27test: declare external dependencies for the testsDmitry Kurochkin
That are: dtach(1), emacs(1), emacsclient(1), gdb(1) and gpg(1).