unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [RFC PATCH 0/3] add user friendly date range search
@ 2011-08-10 10:22 Jani Nikula
  2011-08-10 10:22 ` [RFC PATCH 1/3] Import date/time parser from GNU coreutils Jani Nikula
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Jani Nikula @ 2011-08-10 10:22 UTC (permalink / raw)
  To: notmuch; +Cc: amdragon

Hi, this RFC series adds user friendly date range searches in notmuch.

Patches 1 and 2 add the date/time parser from coreutils, and were posted to
the list by Michal Sojka in January [1]. I picked them up from the
date-parser branch of the git tree at [2]. These worked without
modifications, so I didn't touch them.

Patch 3 adds the actual date range searches on top of current
master. Michal also posted a date search implementation, but it was based
on Austin Clements' custom parser patches, which I haven't looked at. Also,
this one uses date: range syntax rather than before: and after:, and I
think Michal would agree on this one [3].

If the same parser is to be eventually included in notmuch, I'd prefer
using the parse-datetime module [3] (get_date() was renamed) directly from
gnulib [4], instead of coreutils or elsewhere that just imports from
gnulib. Also, I think the gnulib module should be placed in a subdirectory
rather than alongside all the notmuch lib files. However there are some
complications in using parse-datetime, as gnulib modules heavily rely on
autotools. Perhaps one option would be to build a separate library with
autotools that has what we need from gnulib?

Anyway, this is here now, and works (well, with caveats outlined in the
commit message for patch 3) so that people can try this and get a feel of
the date range search. I wouldn't put much efforts to cleanly importing
gnulib before there's some guarantee that the syntax and semantics are
desired in the first place.

Personally, I've been happy with it ever since I got used to the semantics
of the parser.


BR,
Jani.


[1] http://notmuchmail.org/pipermail/notmuch/2011/003749.html
[2] git://rtime.felk.cvut.cz/notmuch.git
[3] http://notmuchmail.org/pipermail/notmuch/2011/004096.html
[4] http://www.gnu.org/s/gnulib/MODULES.html#module=parse-datetime
[3] http://www.gnu.org/s/gnulib/


Jani Nikula (1):
  lib: add gnulib get_date() based date range search

Michal Sojka (2):
  Import date/time parser from GNU coreutils
  Compile the date/time parser into notmuch library

 Makefile.local         |    3 +
 configure              |    8 +
 lib/Makefile.local     |    6 +-
 lib/c-ctype.c          |  398 ++++++
 lib/c-ctype.h          |  297 ++++
 lib/config.h           |   45 +
 lib/database-private.h |    1 +
 lib/database.cc        |    4 +
 lib/getdate-proc.cc    |   32 +
 lib/getdate-proc.h     |   21 +
 lib/getdate.c          | 3506 ++++++++++++++++++++++++++++++++++++++++++++++++
 lib/getdate.h          |   31 +
 lib/getdate.y          | 1581 ++++++++++++++++++++++
 lib/gettime.c          |   48 +
 lib/intprops.h         |   83 ++
 lib/timespec.h         |   39 +
 lib/verify.h           |  140 ++
 17 files changed, 6242 insertions(+), 1 deletions(-)
 create mode 100644 lib/c-ctype.c
 create mode 100644 lib/c-ctype.h
 create mode 100644 lib/config.h
 create mode 100644 lib/getdate-proc.cc
 create mode 100644 lib/getdate-proc.h
 create mode 100644 lib/getdate.c
 create mode 100644 lib/getdate.h
 create mode 100644 lib/getdate.y
 create mode 100644 lib/gettime.c
 create mode 100644 lib/gettime.h
 create mode 100644 lib/intprops.h
 create mode 100644 lib/timespec.h
 create mode 100644 lib/verify.h

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2011-08-23 16:53 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-10 10:22 [RFC PATCH 0/3] add user friendly date range search Jani Nikula
2011-08-10 10:22 ` [RFC PATCH 1/3] Import date/time parser from GNU coreutils Jani Nikula
2011-08-10 10:22 ` [RFC PATCH 2/3] Compile the date/time parser into notmuch library Jani Nikula
2011-08-10 10:22 ` [RFC PATCH 3/3] lib: add gnulib get_date() based date range search Jani Nikula
2011-08-15  9:30   ` Michal Sojka
2011-08-15  9:22 ` [RFC PATCH 0/3] add user friendly " Michal Sojka
2011-08-23 16:39   ` Jason Woofenden
2011-08-23 16:53     ` Tomi Ollila

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).