From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: [PATCH v2] Fix agenda display for late scheduled and deadline tasks Date: Wed, 23 Jun 2010 17:26:03 +0200 Message-ID: <9AA45A0B-7767-4D82-B503-811985BF2093@gmail.com> References: <36E79B10-2D5D-434D-8C81-22E1FA8BDE4E@gmail.com> <1277242816-29777-1-git-send-email-bernt@norang.ca> Mime-Version: 1.0 (Apple Message framework v936) Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Return-path: Received: from [140.186.70.92] (port=41476 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1ORSBq-00071o-GW for emacs-orgmode@gnu.org; Wed, 23 Jun 2010 11:48:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1ORSBp-0008Pq-3L for emacs-orgmode@gnu.org; Wed, 23 Jun 2010 11:48:38 -0400 Received: from mail-wy0-f169.google.com ([74.125.82.169]:51662) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1ORSBo-0008Ph-Qz for emacs-orgmode@gnu.org; Wed, 23 Jun 2010 11:48:37 -0400 Received: by wyf23 with SMTP id 23so709273wyf.0 for ; Wed, 23 Jun 2010 08:48:35 -0700 (PDT) In-Reply-To: <1277242816-29777-1-git-send-email-bernt@norang.ca> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Bernt Hansen Cc: emacs-orgmode@gnu.org Hi Bernt, can you point me to the thread which discusses this issue? Thanks. - Carsten On Jun 22, 2010, at 11:40 PM, Bernt Hansen wrote: > * lisp/org.el (org-time-string-to-absolute): > > Ignore the cyclic repeater when displaying items on today's agenda > date. If you have a weekly task and miss the date the agenda view > will show more than a week late now instead of resetting on the > cyclic repeating date. This makes it much more obvious when you > missed a repeating task after the repeater. > --- > Here's a new version of this patch which I think addresses Matt's > issue and it's simpler > which is always a bonus. > > The patch is available at git://git.norang.ca/org-mode.git fix- > agenda-late-tasks > > -Bernt > > > lisp/org.el | 21 +++++++++++---------- > 1 files changed, 11 insertions(+), 10 deletions(-) > > diff --git a/lisp/org.el b/lisp/org.el > index 2628152..4ebf31d 100644 > --- a/lisp/org.el > +++ b/lisp/org.el > @@ -14700,16 +14700,17 @@ If there is a specifyer for a cyclic time > stamp, get the closest date to > DAYNR. > PREFER and SHOW-ALL are passed through to `org-closest-date'. > the variable date is bound by the calendar when this is called." > - (cond > - ((and daynr (string-match "\\`%%\\((.*)\\)" s)) > - (if (org-diary-sexp-entry (match-string 1 s) "" date) > - daynr > - (+ daynr 1000))) > - ((and daynr (string-match "\\+[0-9]+[dwmy]" s)) > - (org-closest-date s (if (and (boundp 'daynr) (integerp daynr)) > daynr > - (time-to-days (current-time))) (match-string 0 s) > - prefer show-all)) > - (t (time-to-days (apply 'encode-time (org-parse-time-string > s)))))) > + (let ((today (calendar-absolute-from-gregorian (calendar-current- > date)))) > + (cond > + ((and daynr (string-match "\\`%%\\((.*)\\)" s)) > + (if (org-diary-sexp-entry (match-string 1 s) "" date) > + daynr > + (+ daynr 1000))) > + ((and daynr (not (eq daynr today)) (string-match "\\+[0-9]+ > [dwmy]" s)) > + (org-closest-date s (if (and (boundp 'daynr) (integerp daynr)) > daynr > + (time-to-days (current-time))) (match-string 0 s) > + prefer show-all)) > + (t (time-to-days (apply 'encode-time (org-parse-time-string > s))))))) > > (defun org-days-to-iso-week (days) > "Return the iso week number." > -- > 1.7.1.359.gd0b8d > > > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode - Carsten