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 736354196F0 for ; Thu, 10 Jun 2010 07:03:13 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: -4.2 X-Spam-Level: X-Spam-Status: No, score=-4.2 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3] autolearn=ham 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 G4bJTpAHzsg0 for ; Thu, 10 Jun 2010 07:03:01 -0700 (PDT) Received: from bombadil.infradead.org (bombadil.infradead.org [18.85.46.34]) by olra.theworths.org (Postfix) with ESMTP id C8284431FC1 for ; Thu, 10 Jun 2010 07:03:01 -0700 (PDT) Received: from localhost ([::1] helo=x201s.gr8dns.org) by bombadil.infradead.org with esmtp (Exim 4.72 #1 (Red Hat Linux)) id 1OMiLU-0006nG-1J; Thu, 10 Jun 2010 14:03:00 +0000 Received: by x201s.gr8dns.org (Postfix, from userid 500) id 151B8253915; Thu, 10 Jun 2010 07:00:57 -0700 (PDT) From: Dirk Hohndel To: David Edmondson , notmuch Subject: Re: fix problem with notmuch-hello-nice-number In-Reply-To: <87mxv3s6za.fsf@ut.hh.sledj.net> References: <87mxv3s6za.fsf@ut.hh.sledj.net> User-Agent: Notmuch/0.3.1-70-g259d48b (http://notmuchmail.org) Emacs/23.2.1 (x86_64-redhat-linux-gnu) Date: Thu, 10 Jun 2010 07:00:57 -0700 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org See http://www.infradead.org/rpr.html 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: Thu, 10 Jun 2010 14:03:13 -0000 On Thu, 10 Jun 2010 08:05:13 +0100, David Edmondson wrote: > On Wed, 09 Jun 2010 07:49:01 -0700, Dirk Hohndel wrote: > > Without this little patch notmuch fails with current git if there's a > > saved search that has zero results > > How about: > > diff --git a/emacs/notmuch-hello.el b/emacs/notmuch-hello.el > index a6e8a47..48bb6e3 100644 > --- a/emacs/notmuch-hello.el > +++ b/emacs/notmuch-hello.el > @@ -115,6 +115,7 @@ Typically \",\" in the US and UK and \".\" in Europe." > (while (> n 0) > (push (% n 1000) result) > (setq n (/ n 1000))) > + (setq result (or result '(0))) > (apply #'concat > (number-to-string (car result)) > (mapcar (lambda (elem) > Much better. Mine made sense when you looked at it - this one has a much more emacs-y feel to it in that I need to stare at it for 30 seconds before I can grasp what it does :-) /D -- Dirk Hohndel Intel Open Source Technology Center