Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id B4428431FC0 for ; Sat, 8 Dec 2012 17:53:42 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id WRyKEJNVIJNa for ; Sat, 8 Dec 2012 17:53:41 -0800 (PST) Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) by olra.theworths.org (Postfix) with ESMTP id B98FC431FAE for ; Sat, 8 Dec 2012 17:53:41 -0800 (PST) Received: from guru.guru-group.fi (localhost [IPv6:::1]) by guru.guru-group.fi (Postfix) with ESMTP id 8B503100030; Sun, 9 Dec 2012 03:53:36 +0200 (EET) From: Tomi Ollila To: Jani Nikula , Jameson Graef Rollins , David Bremner , notmuch@notmuchmail.org Subject: Re: [PATCH] TODO: date range queries - check In-Reply-To: <87sj7gp43x.fsf@nikula.org> References: <1354833276-6219-1-git-send-email-jani@nikula.org> <877gouine4.fsf@servo.finestructure.net> <871uf2ukat.fsf@zancas.localnet> <877gothkzw.fsf@servo.finestructure.net> <87624dzgso.fsf@nikula.org> <87boe5fsdn.fsf@servo.finestructure.net> <87r4n0smot.fsf@zancas.localnet> <871uf0fdnh.fsf@servo.finestructure.net> <87sj7gp43x.fsf@nikula.org> User-Agent: Notmuch/0.14+116~g29fcdb5 (http://notmuchmail.org) Emacs/24.2.1 (x86_64-unknown-linux-gnu) X-Face: HhBM'cA~ MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Dec 2012 01:53:42 -0000 On Sun, Dec 09 2012, Jani Nikula wrote: > On Sat, 08 Dec 2012, Jameson Graef Rollins wrote: >> On Sat, Dec 08 2012, David Bremner wrote: >>> Patch? Concrete wording suggestion? >> >> How about: >> >> It would be nice to not require both endpoints to be specified in date >> searches. For example it would be nice to be able to say things like >> "date:2009-01-1", to specify a search over a particular day, or >> "since:'1 month' to specify an open-ended range, and have the other >> endpoint be implicit. To do any of this we're probably going to need to >> break down an write our own parser for the query string rather than >> using Xapian's QueryParser class. > > FWIW, this means, in practice: > > Make date: an alias for date:.. > > Make since: an alias for date:.. > > Make until: an alias for date:.. I personally don't desire since: and until: prefixes (and as not being native english speaker maybe more so) I'd like to also drop the 'date:' part (just for convenience, nothing against using english word there ;) and use only e.g. 1d.. (and so on). Actually I am (still) running my hacky wrapper which converts strings like '1d..' found in command line to '..' before passing the command line to notmuch. I find it very convenient... e.g. IMHO ..yesterday would be more convenient than since:yesterday > > We'll either need to write our own query parser or some new features to > upstream Xapian to do any of these. > BR, > Jani. FWIW Tomi