From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alan Schmitt Subject: tiny patch for org-expiry Date: Sat, 12 Apr 2014 12:36:27 +0200 Message-ID: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:39417) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WYvIh-0008K6-17 for emacs-orgmode@gnu.org; Sat, 12 Apr 2014 06:36:49 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WYvIV-0007LK-JO for emacs-orgmode@gnu.org; Sat, 12 Apr 2014 06:36:42 -0400 Received: from mail2-relais-roc.national.inria.fr ([192.134.164.83]:37914) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WYvIV-0007Ks-CS for emacs-orgmode@gnu.org; Sat, 12 Apr 2014 06:36:31 -0400 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode --=-=-= Content-Type: text/plain Hello, I'm trying to write some code to schedule reviews of projects, and I'm basing it on org-expiry. I found a couple of tiny bugs with it, which may be fixed with this patch. Best, Alan --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-Org-expiry-make-code-and-doc-consistent.patch >From f38fe30c5c6115d33755a1c9f052cb01d1434d79 Mon Sep 17 00:00:00 2001 From: Alan Schmitt Date: Sat, 12 Apr 2014 12:32:42 +0200 Subject: [PATCH] Org-expiry: make code and doc consistent * contrib/lisp/org-expiry.el (org-expiry-expired-p): make code and doc string consistent. --- contrib/lisp/org-expiry.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/contrib/lisp/org-expiry.el b/contrib/lisp/org-expiry.el index d58043f..33f8ea1 100644 --- a/contrib/lisp/org-expiry.el +++ b/contrib/lisp/org-expiry.el @@ -218,11 +218,12 @@ Return nil if the entry is not expired. Otherwise return the amount of time between today and the expiry date. If there is no creation date, use `org-expiry-created-date'. -If there is no expiry date, use `org-expiry-expiry-date'." +If there is no expiry date, use `org-expiry-wait'." (let* ((ex-prop org-expiry-expiry-property-name) (cr-prop org-expiry-created-property-name) (ct (current-time)) - (cr (org-read-date nil t (or (org-entry-get (point) cr-prop t) "+0d"))) + (cr (org-read-date nil t (or (org-entry-get (point) cr-prop t) + org-expiry-created-date))) (ex-field (or (org-entry-get (point) ex-prop t) org-expiry-wait)) (ex (if (string-match "^[ \t]?[+-]" ex-field) (time-add cr (time-subtract (org-read-date nil t ex-field) ct)) -- 1.8.5.3 --=-=-=--