emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] [PATCH] Reschedule "++" repeaters on same day if in future


From: Don March
Subject: Re: [O] [PATCH] Reschedule "++" repeaters on same day if in future
Date: Thu, 30 Jun 2016 19:07:13 -0400

Nicolas Goaziou <address@hidden> writes:

> Don March <address@hidden> writes:

>> If you have a task with the following timestamp:
>>
>>     SCHEDULED: <2016-06-19 Sun 21:00 ++1w>
>>
>> then marking it as DONE at [2016-06-27 at 07:00] should [...]

> ISYM [2016-06-26 at 07:00].

Yes :) Thanks for understanding anyway. (and ITYM "ITYM", maybe?)

> You should merge both `or'. Also, (equal time (current-time)) is always
> nil since they don't have the same structure.

You're right about both things.  I updated the patch, and also added an
example to the manual.  If that's not what you had it mind, let me know
or feel free to edit.


On Thu, Jun 30, 2016 at 8:16 AM, Nicolas Goaziou <address@hidden> wrote:
> Hello,
>
> Don March <address@hidden> writes:
>
>> If you have a task with the following timestamp:
>>
>>     SCHEDULED: <2016-06-19 Sun 21:00 ++1w>
>>
>> then marking it as DONE at [2016-06-27 at 07:00] should (debatably)
>> result in
>
> ISYM [2016-06-26 at 07:00].
>
>>     SCHEDULED: <2016-06-26 Sun 21:00 ++1w>
>>
>> but instead it becomes
>>
>>     SCHEDULED: <2016-07-03 Sun 21:00 ++1w>
>
> With the correction above, it makes sense, indeed.
>
>> -                                  (<= (time-to-days time)
>> -                                      (time-to-days (current-time))))
>> +                                  (or (time-less-p time (current-time))
>> +                                      (equal time (current-time))))
>
> You should merge both `or'. Also, (equal time (current-time)) is always
> nil since they don't have the same structure.
>
> You could write instead
>
>   (while (or (= nshift 0)
>              (not (time-less-p (current-time) time)))
>     ...)
>
> It would be nice to add an explanation along with an example about that
> in the manual, too. WDYT?
>
> Thank you for your patch.
>
> Regards,
>
> --
> Nicolas Goaziou

Attachment: 0001-Reschedule-repeaters-on-same-day-if-in-future.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]