0

I have a deadline that is some date in the past(such as 12/26/2019) + interval (e.g. 15d). How would I get it in Emacs? In a previous post under the same title I posted an example with interval = the sum of the two subintervals (15d+1m). Someone answered that would have to be a feature request, but was able to do it with only one interval. Actually, that is all I need, but still don't know how to do it. Would someone be so kind as to give a step by step instruction to do it?

Bottom line: how to get '12/26/2019+15d'?

enter image description here

1 Answer 1

0

Given a timestamp of 2019-12-12, you can specify ++15d (note the double plus) to move forward to 2019-12-27, then you can specify ++1m to move forward to 2020-01-27. See the section of the manual entitled The date/time prompt:

With a single plus or minus, the date is always relative to today. With a double plus or minus, it is relative to the default date.

EDIT: Here's a more detailed workflow. The simplest method I know to do what you want is to use the date/time prompt and select your initial date from the calendar: e.g. for a SCHEDULE: date, say C-c C-s and click on 2019-12-12. That makes 2019-12-12 the default date, so you can say C-c C-s again and type ++15d at the date/time prompt: that gets you to 2019-12-27 which is now the new default date. So you can do C-c C-s one more time and say ++1m at the prompt to get you to 2020-01-27. Does that help?

Note that with C-c ., every time you modify the date, the cursor ends up after the date, so if you do it again, you end up with a date range. Just move the cursor back into the date before repeating it and you will not get a second date.

3
  • I can do it like this: C-c . Dp S-< as many times as needed to get to 12-26. Then RET. Then C-c . ++15d RET, and I end up with two timestamps, one for 12-26, another for 01/10. I just need the second. It works, but is there a less cumbersome way?
    – user19777
    Jan 14, 2020 at 17:48
  • Edited the answer with a more detailed workflow.
    – NickD
    Jan 14, 2020 at 18:50
  • 1
    Edited again to point out why C-c . gives you a second date.
    – NickD
    Jan 14, 2020 at 18:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.